Move home and library titles higher
This commit is contained in:
1 parent
36220e46ea
commit
fad462f5b4
4 files changed
+22
-6
No files matched your search
@@ -143,6 +143,7 @@ struct AlbumDetailView: View {
|
||||
)
|
||||
}
|
||||
}
|
||||
.toolbar(.visible, for: .navigationBar)
|
||||
.navigationTitle("")
|
||||
.navigationBarTitleDisplayMode(.inline)
|
||||
.tint(.red)
|
||||
|
||||
@@ -123,7 +123,7 @@ struct ArtistDetailView: View {
|
||||
description: Text("This artist may no longer be available."))
|
||||
}
|
||||
}
|
||||
.toolbar(.hidden, for: .navigationBar)
|
||||
.toolbar(.visible, for: .navigationBar)
|
||||
.navigationTitle("")
|
||||
.navigationBarTitleDisplayMode(.inline)
|
||||
.tint(.red)
|
||||
|
||||
@@ -10,6 +10,13 @@ struct HomeView: View {
|
||||
var body: some View {
|
||||
NavigationStack {
|
||||
ScrollView {
|
||||
VStack(alignment: .leading, spacing: 0) {
|
||||
Text("Home")
|
||||
.font(.system(size: 34, weight: .bold))
|
||||
.padding(.horizontal, 20)
|
||||
.padding(.top, 4)
|
||||
.padding(.bottom, 16)
|
||||
|
||||
Group {
|
||||
if viewModel.sections.isEmpty, viewModel.isLoading {
|
||||
ProgressView()
|
||||
@@ -48,12 +55,12 @@ struct HomeView: View {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.scrollIndicators(.hidden)
|
||||
.refreshable {
|
||||
await viewModel.load(forceRefresh: true)
|
||||
}
|
||||
.navigationTitle("Home")
|
||||
.navigationBarTitleDisplayMode(.large)
|
||||
.toolbar(.hidden, for: .navigationBar)
|
||||
.tint(.red)
|
||||
}
|
||||
.task {
|
||||
|
||||
@@ -146,13 +146,21 @@ private struct TabAccessoryVisibilityBridge: UIViewControllerRepresentable {
|
||||
private struct LibraryTabView: View {
|
||||
var body: some View {
|
||||
NavigationStack {
|
||||
VStack(alignment: .leading, spacing: 0) {
|
||||
Text("Library")
|
||||
.font(.system(size: 34, weight: .bold))
|
||||
.padding(.horizontal, 20)
|
||||
.padding(.top, 4)
|
||||
.padding(.bottom, 16)
|
||||
|
||||
ContentUnavailableView(
|
||||
"Your Library",
|
||||
"No Saved Songs",
|
||||
systemImage: "books.vertical",
|
||||
description: Text("Your saved songs will appear here.")
|
||||
)
|
||||
.navigationTitle("Library")
|
||||
.navigationBarTitleDisplayMode(.large)
|
||||
.frame(maxWidth: .infinity, maxHeight: .infinity)
|
||||
}
|
||||
.toolbar(.hidden, for: .navigationBar)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user