Use the macOS capsule mini player on iOS 18 and drop its duplicate close button

The iOS 18 overlay layout appended a hardcoded close button after the
preset buttons, and the default mini player preset already includes
Close, so the bar showed two X buttons. Replace the full-width material
bar with the same 420pt capsule macOS uses (shared capsuleLayout), and
only add the fallback close button when the active preset has none.

Inset the iOS 18 overlay 16pt horizontally; clear the bottom tab bar in
compact width and float 12pt above the edge in regular width, where
sidebarAdaptable keeps the tabs at the top.
This commit is contained in:
Arkadiusz Fal
2026-09-27 22:09:22 +02:00
parent d2fb465234
commit 5786a0210a
2 changed files with 26 additions and 58 deletions

View File

@@ -289,7 +289,10 @@ struct iOS18AdaptiveTabView: View {
Spacer()
MiniPlayerView()
}
.padding(.bottom, 49)
.padding(.horizontal, 16)
// Compact width has a bottom tab bar (49pt) to clear; regular width
// (sidebarAdaptable) keeps its tabs at the top, so only float above the edge.
.padding(.bottom, horizontalSizeClass == .compact ? 49 + 8 : 12)
// Use move-only transition (no opacity) to prevent thumbnail flash during collapse
// The opacity transition caused video to appear faded during player sheet dismiss
.transition(.move(edge: .bottom))