iPhone SwiftUI layouts
Explore SwiftUI APIs, components, and modifiers with interactive iPhone previews, Swift code, and Apple documentation. Compare every available orientation, appearance, and design.
201elements
Toolbars
ToolbarItem Shared Background Visibility
Controls the visibility of the glass background effect on items in the toolbar. In certain contexts, such as the navigation bar on iOS and the window toolbar on macOS, toolbar items will be given a glass background effect that is shared with other items in the same logical grouping
Explore ToolbarItem Shared Background Visibility on iPhone in portrait, with SwiftUI code and Apple API documentation.
SwiftUI code
NavigationStack {
Text("Foo")
.toolbar {
ToolbarItem {
Button("Account", systemImage: "person.circle", action: action)
}
ToolbarItem {
Button("Account", systemImage: "person.circle", action: action)
}
.sharedBackgroundVisibility(.hidden)
}
}Compatibility
iOS 26.0+ iPadOS 26.0+ macOS 26.0+
Tags
Found an issue or have a suggestion?
All variants
Every available iPhone screenshot for ToolbarItem Shared Background Visibility.