Move home and library titles higher

This commit is contained in:
lucast committed 2026-10-07 23:53:37 +02:00
1 parent 36220e46ea
commit fad462f5b4
4 files changed
+22 -6

No files matched your search

+1
View File
@@ -143,6 +143,7 @@ struct AlbumDetailView: View {
) )
} }
} }
.toolbar(.visible, for: .navigationBar)
.navigationTitle("") .navigationTitle("")
.navigationBarTitleDisplayMode(.inline) .navigationBarTitleDisplayMode(.inline)
.tint(.red) .tint(.red)
+1 -1
View File
@@ -123,7 +123,7 @@ struct ArtistDetailView: View {
description: Text("This artist may no longer be available.")) description: Text("This artist may no longer be available."))
} }
} }
.toolbar(.hidden, for: .navigationBar) .toolbar(.visible, for: .navigationBar)
.navigationTitle("") .navigationTitle("")
.navigationBarTitleDisplayMode(.inline) .navigationBarTitleDisplayMode(.inline)
.tint(.red) .tint(.red)
+9 -2
View File
@@ -10,6 +10,13 @@ struct HomeView: View {
var body: some View { var body: some View {
NavigationStack { NavigationStack {
ScrollView { ScrollView {
VStack(alignment: .leading, spacing: 0) {
Text("Home")
.font(.system(size: 34, weight: .bold))
.padding(.horizontal, 20)
.padding(.top, 4)
.padding(.bottom, 16)
Group { Group {
if viewModel.sections.isEmpty, viewModel.isLoading { if viewModel.sections.isEmpty, viewModel.isLoading {
ProgressView() ProgressView()
@@ -48,12 +55,12 @@ struct HomeView: View {
} }
} }
} }
}
.scrollIndicators(.hidden) .scrollIndicators(.hidden)
.refreshable { .refreshable {
await viewModel.load(forceRefresh: true) await viewModel.load(forceRefresh: true)
} }
.navigationTitle("Home") .toolbar(.hidden, for: .navigationBar)
.navigationBarTitleDisplayMode(.large)
.tint(.red) .tint(.red)
} }
.task { .task {
+11 -3
View File
@@ -146,13 +146,21 @@ private struct TabAccessoryVisibilityBridge: UIViewControllerRepresentable {
private struct LibraryTabView: View { private struct LibraryTabView: View {
var body: some View { var body: some View {
NavigationStack { NavigationStack {
VStack(alignment: .leading, spacing: 0) {
Text("Library")
.font(.system(size: 34, weight: .bold))
.padding(.horizontal, 20)
.padding(.top, 4)
.padding(.bottom, 16)
ContentUnavailableView( ContentUnavailableView(
"Your Library", "No Saved Songs",
systemImage: "books.vertical", systemImage: "books.vertical",
description: Text("Your saved songs will appear here.") description: Text("Your saved songs will appear here.")
) )
.navigationTitle("Library") .frame(maxWidth: .infinity, maxHeight: .infinity)
.navigationBarTitleDisplayMode(.large) }
.toolbar(.hidden, for: .navigationBar)
} }
} }
} }