Fix broken modifier chain around playback speed menu style

This commit is contained in:
Arkadiusz Fal
2026-04-14 19:18:24 +02:00
parent c7d1f1c20b
commit 2dcfe52bfb

View File

@@ -343,11 +343,7 @@ extension QualitySelectorView {
.fixedSize(horizontal: true, vertical: false) .fixedSize(horizontal: true, vertical: false)
.frame(minWidth: 80) .frame(minWidth: 80)
} }
#if os(tvOS) .playbackSpeedMenuStyle()
// Default menu style on tvOS renders a focusable bordered pill.
#else
.menuStyle(.borderlessButton)
#endif
Button { Button {
if let newRate = nextRate() { if let newRate = nextRate() {
@@ -822,3 +818,14 @@ struct TVSettingsRowButtonStyle: ButtonStyle {
} }
} }
#endif #endif
private extension View {
@ViewBuilder
func playbackSpeedMenuStyle() -> some View {
#if os(tvOS)
self
#else
self.menuStyle(.borderlessButton)
#endif
}
}