mirror of
https://github.com/yattee/yattee.git
synced 2024-12-22 21:43:41 +00:00
Switch to horizontal cells for playlists on tvOS
This commit is contained in:
parent
ef5c75a2bc
commit
4d4248662d
@ -26,15 +26,20 @@ struct PlaylistsView: View {
|
|||||||
VStack {
|
VStack {
|
||||||
#if os(tvOS)
|
#if os(tvOS)
|
||||||
toolbar
|
toolbar
|
||||||
.font(.system(size: 28))
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if model.currentPlaylist != nil, videos.isEmpty {
|
if model.currentPlaylist != nil, videos.isEmpty {
|
||||||
hintText("Playlist is empty\n\nTap and hold on a video and then tap \"Add to Playlist\"")
|
hintText("Playlist is empty\n\nTap and hold on a video and then tap \"Add to Playlist\"")
|
||||||
} else if model.all.isEmpty {
|
} else if model.all.isEmpty {
|
||||||
hintText("You have no playlists\n\nTap on \"New Playlist\" to create one")
|
hintText("You have no playlists\n\nTap on \"New Playlist\" to create one")
|
||||||
} else {
|
} else {
|
||||||
VideosCellsVertical(videos: videos)
|
#if os(tvOS)
|
||||||
|
VideosCellsHorizontal(videos: videos)
|
||||||
|
.padding(.top, 40)
|
||||||
|
Spacer()
|
||||||
|
#else
|
||||||
|
VideosCellsVertical(videos: videos)
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -31,13 +31,11 @@ struct TrendingView: View {
|
|||||||
toolbar
|
toolbar
|
||||||
VideosCellsHorizontal(videos: store.collection)
|
VideosCellsHorizontal(videos: store.collection)
|
||||||
.padding(.top, 40)
|
.padding(.top, 40)
|
||||||
|
|
||||||
|
Spacer()
|
||||||
#else
|
#else
|
||||||
VideosCellsVertical(videos: store.collection)
|
VideosCellsVertical(videos: store.collection)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if os(tvOS)
|
|
||||||
Spacer()
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#if os(tvOS)
|
#if os(tvOS)
|
||||||
|
Loading…
Reference in New Issue
Block a user