Revert "Add loading status to vertical cells"

This reverts commit c6cff4dee4.
This commit is contained in:
Arkadiusz Fal
2023-06-07 22:32:54 +02:00
parent 5ee869c02c
commit 56c2e552f7
12 changed files with 127 additions and 178 deletions

View File

@@ -70,7 +70,7 @@ struct PlaylistVideosView: View {
}
var body: some View {
VerticalCells(items: contentItems, isLoading: resource?.isLoading ?? false)
VerticalCells(items: contentItems)
.onAppear {
guard contentItems.isEmpty else { return }
loadResource()

View File

@@ -63,11 +63,13 @@ struct PlaylistsView: View {
var body: some View {
SignInRequiredView(title: "Playlists".localized()) {
VStack {
VerticalCells(items: items, isLoading: resource?.isLoading ?? false) { if shouldDisplayHeader { header } }
VerticalCells(items: items, allowEmpty: true) { if shouldDisplayHeader { header } }
.environment(\.currentPlaylistID, currentPlaylist?.id)
.environment(\.listingStyle, playlistListingStyle)
if model.all.isEmpty {
if currentPlaylist != nil, items.isEmpty {
hintText("Playlist is empty\n\nTap and hold on a video and then \n\"Add to Playlist\"".localized())
} else if model.all.isEmpty {
hintText("You have no playlists\n\nTap on \"New Playlist\" to create one".localized())
}
}