diff --git a/Delta/Base.lproj/Settings.storyboard b/Delta/Base.lproj/Settings.storyboard index 5a79b22..3f986ce 100644 --- a/Delta/Base.lproj/Settings.storyboard +++ b/Delta/Base.lproj/Settings.storyboard @@ -19,7 +19,7 @@ - + @@ -29,7 +29,7 @@ - + @@ -52,7 +52,7 @@ - + @@ -75,7 +75,7 @@ - + @@ -98,7 +98,7 @@ - + @@ -125,7 +125,7 @@ - + @@ -141,7 +141,7 @@ - + @@ -157,7 +157,7 @@ - + @@ -173,7 +173,7 @@ - + @@ -189,7 +189,7 @@ - + @@ -205,7 +205,7 @@ - + @@ -221,7 +221,7 @@ - + @@ -241,7 +241,7 @@ - + @@ -281,7 +281,7 @@ - + @@ -315,7 +315,7 @@ - + @@ -345,7 +345,7 @@ - + @@ -379,7 +379,7 @@ - + @@ -405,7 +405,7 @@ - + @@ -428,7 +428,7 @@ - + @@ -447,7 +447,7 @@ - + @@ -481,7 +481,7 @@ - + @@ -508,7 +508,7 @@ - + @@ -528,7 +528,7 @@ - + @@ -548,7 +548,7 @@ - + @@ -571,7 +571,7 @@ - + @@ -594,7 +594,7 @@ - + @@ -617,7 +617,7 @@ - + @@ -640,7 +640,7 @@ - + @@ -663,7 +663,7 @@ - + @@ -679,7 +679,7 @@ - + @@ -705,7 +705,7 @@ - + @@ -866,7 +866,7 @@ - + @@ -888,7 +888,7 @@ - + @@ -911,7 +911,7 @@ - + @@ -993,7 +993,7 @@ - + @@ -1070,8 +1070,8 @@ - - + + @@ -1292,6 +1292,7 @@ + @@ -1354,6 +1355,7 @@ + @@ -2251,7 +2253,7 @@ Delta uses OpenVGDB to provide automatic artwork for imported games. - + diff --git a/Delta/Settings/Contributors/ContributorsView.swift b/Delta/Settings/Contributors/ContributorsView.swift index 9edd7e5..2b8ac14 100644 --- a/Delta/Settings/Contributors/ContributorsView.swift +++ b/Delta/Settings/Contributors/ContributorsView.swift @@ -59,7 +59,8 @@ extension ContributorsView let contributorsView = ContributorsView(viewModel: viewModel) let hostingController = UIHostingController(rootView: contributorsView) - hostingController.title = NSLocalizedString("Contributors", comment: "") + hostingController.navigationItem.largeTitleDisplayMode = .never + hostingController.navigationItem.title = contributorsView.localizedTitle viewModel.hostingController = hostingController @@ -76,6 +77,8 @@ struct ContributorsView: View @State private var showErrorAlert: Bool = false + private var localizedTitle: String { NSLocalizedString("Contributors", comment: "") } + var body: some View { List { Section(content: {}, footer: { @@ -100,6 +103,8 @@ struct ContributorsView: View } } .listStyle(.insetGrouped) + .navigationTitle(localizedTitle) + .navigationBarTitleDisplayMode(.inline) .environmentObject(viewModel) .alert(isPresented: $showErrorAlert) { Alert(title: Text("Unable to Load Contributors"), message: Text(viewModel.error?.localizedDescription ?? ""), dismissButton: .default(Text("OK")) { diff --git a/Delta/Settings/Experimental Features/ExperimentalFeaturesView.swift b/Delta/Settings/Experimental Features/ExperimentalFeaturesView.swift index d233607..53f50df 100644 --- a/Delta/Settings/Experimental Features/ExperimentalFeaturesView.swift +++ b/Delta/Settings/Experimental Features/ExperimentalFeaturesView.swift @@ -33,6 +33,8 @@ struct ExperimentalFeaturesView: View @StateObject private var viewModel: ViewModel = ViewModel() + private var localizedTitle: String { NSLocalizedString("Experimental Features", comment: "") } + var body: some View { Form { Section(content: {}, footer: { @@ -45,8 +47,10 @@ struct ExperimentalFeaturesView: View } } .listStyle(.insetGrouped) + .navigationTitle(localizedTitle) + .navigationBarTitleDisplayMode(.inline) } - + // Cannot open existential if return type uses concrete type T in non-covariant position (e.g. Box). // So instead we erase return type to AnyView. private func section(for feature: T) -> AnyView @@ -63,7 +67,8 @@ extension ExperimentalFeaturesView let experimentalFeaturesView = ExperimentalFeaturesView() let hostingController = UIHostingController(rootView: experimentalFeaturesView) - hostingController.title = NSLocalizedString("Experimental Features", comment: "") + hostingController.navigationItem.largeTitleDisplayMode = .never + hostingController.navigationItem.title = experimentalFeaturesView.localizedTitle return hostingController } }