diff options
Diffstat (limited to 'Sora/Views/PlatformSpecificToolbarItem.swift')
| -rw-r--r-- | Sora/Views/PlatformSpecificToolbarItem.swift | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/Sora/Views/PlatformSpecificToolbarItem.swift b/Sora/Views/PlatformSpecificToolbarItem.swift index 4a44db0..578affe 100644 --- a/Sora/Views/PlatformSpecificToolbarItem.swift +++ b/Sora/Views/PlatformSpecificToolbarItem.swift @@ -5,13 +5,17 @@ struct PlatformSpecificToolbarItem<Content: View>: ToolbarContent { let content: () -> Content init( - placement: ToolbarItemPlacement?, + placement: ToolbarItemPlacement? = nil, @ViewBuilder content: @escaping () -> Content ) { #if os(macOS) self.placement = .automatic #else - self.placement = placement ?? .bottomBar + if #available(iOS 26, *) { + self.placement = placement ?? .secondaryAction + } else { + self.placement = placement ?? .bottomBar + } #endif self.content = content |