diff --git a/NucleicRemote/NucleicRemote/Views/AdaptiveRootView.swift b/NucleicRemote/NucleicRemote/Views/AdaptiveRootView.swift index a4c68b3..a2240d4 100644 --- a/NucleicRemote/NucleicRemote/Views/AdaptiveRootView.swift +++ b/NucleicRemote/NucleicRemote/Views/AdaptiveRootView.swift @@ -120,12 +120,27 @@ struct CompactRootView: View { } /// A preference carrying the floating bar's measured height up to `CompactRootView`, which feeds it -/// back into the bottom safe-area inset so content sits exactly above the bar. +/// back into each tab's bottom inset so content sits exactly above the bar. private struct BarHeightKey: PreferenceKey { static var defaultValue: CGFloat = 72 static func reduce(value: inout CGFloat, nextValue: () -> CGFloat) { value = nextValue() } } +/// Per-tab chrome for the compact shell: suppress the system tab bar (we draw our own) and reserve +/// `height` at the bottom of this tab's content so its scroll view lays out above the floating bar. +/// Applied to each tab rather than the `TabView`, whose container-level inset doesn't reach the tab +/// pages' scroll content. +private struct TabBarInset: ViewModifier { + let height: CGFloat + func body(content: Content) -> some View { + content + .toolbar(.hidden, for: .tabBar) + .safeAreaInset(edge: .bottom, spacing: 0) { + Color.clear.frame(height: height) + } + } +} + /// Our own bottom tab bar for the compact shell — a floating Liquid Glass capsule of four items /// (Home, Sessions, Projects, Settings), standing in for the system tab bar so `CompactRootView` /// can animate its visibility itself (see that view for why) while keeping the iOS 26 floating-glass