From 1f7c471fcc53597e5fc89d8fb8dfb3899a678c86 Mon Sep 17 00:00:00 2001 From: Arkadiusz Fal Date: Fri, 16 Oct 2026 23:59:09 +0200 Subject: [PATCH] Give the tvOS media-source-not-found screen an Open Sources button A media source destination whose source was removed rendered a bare ContentUnavailableView, so the remote had nothing to focus. --- Yattee/Localizable.xcstrings | 11 +++++++++++ .../Services/Navigation/NavigationDestination.swift | 8 ++++++++ 2 files changed, 19 insertions(+) diff --git a/Yattee/Localizable.xcstrings b/Yattee/Localizable.xcstrings index 3959c34b..10b48f8e 100644 --- a/Yattee/Localizable.xcstrings +++ b/Yattee/Localizable.xcstrings @@ -7202,6 +7202,17 @@ } } }, + "navigation.sourceNotFound.openSources" : { + "comment" : "tvOS button on the media-source-not-found screen that opens the Sources list", + "localizations" : { + "en" : { + "stringUnit" : { + "state" : "translated", + "value" : "Open Sources" + } + } + } + }, "Next" : { }, diff --git a/Yattee/Services/Navigation/NavigationDestination.swift b/Yattee/Services/Navigation/NavigationDestination.swift index a0372577..9898cd6a 100644 --- a/Yattee/Services/Navigation/NavigationDestination.swift +++ b/Yattee/Services/Navigation/NavigationDestination.swift @@ -190,6 +190,14 @@ private struct MediaSourceByIDView: View { Label(String(localized: "navigation.sourceNotFound"), systemImage: "externaldrive.badge.exclamationmark") } description: { Text(String(localized: "navigation.sourceNotFound.description")) + } actions: { + #if os(tvOS) + // Nothing else here is focusable, and as a sidebar source this + // is a tab root that Menu cannot pop. + Button(String(localized: "navigation.sourceNotFound.openSources")) { + appEnvironment?.navigationCoordinator.router.select(.sources) + } + #endif } } }