// // LibraryIconView.swift // Jel // // Created by zerocool on 12/15/23. // import SwiftUI import JellyfinKit import BlurHashKit struct LibraryIconView: View { @EnvironmentObject var jellyfinClient: JellyfinClientController @State var library: BaseItemDto @State var loadingImage: Bool = true @State var loadedImageBinaryData: Data? var body: some View { VStack { AsyncImageView(imageId: library.id ?? "", blurhash: library.imageBlurHashes?.primary?[library.imageTags?["Primary"] ?? ""] ?? "", imageType: "Primary") Text(library.name ?? "Unknown") .font(.subheadline) } } } #Preview { LibraryIconView(library: BaseItemDto()) }