yattee/Shared/Views/ContentItemView.swift

22 lines
496 B
Swift
Raw Normal View History

import Foundation
import SwiftUI
struct ContentItemView: View {
let item: ContentItem
var body: some View {
Group {
switch item.contentType {
2022-08-13 14:46:45 +00:00
case .video:
VideoCell(video: item.video)
case .playlist:
2021-10-22 23:04:03 +00:00
ChannelPlaylistCell(playlist: item.playlist)
case .channel:
ChannelCell(channel: item.channel)
2022-03-27 10:49:57 +00:00
default:
PlaceholderCell()
}
}
}
}