diff --git a/Sources/ShowcaseFuse/ContentView.swift b/Sources/ShowcaseFuse/ContentView.swift index a4af928..707409b 100644 --- a/Sources/ShowcaseFuse/ContentView.swift +++ b/Sources/ShowcaseFuse/ContentView.swift @@ -31,6 +31,20 @@ struct ContentView: View { Label("Settings", systemImage: "gearshape.fill") } } + .modify { + if #available(iOS 18.0, *) { + $0.tabViewStyle(.automatic) + } else { + $0 + } + } .preferredColorScheme(appearance == "dark" ? .dark : appearance == "light" ? .light : nil) } } + +public extension View { + @ViewBuilder + func modify(@ViewBuilder _ transform: (Self) -> T) -> some View { + transform(self) + } +}