diff options
Diffstat (limited to 'Jel/Views/Dashboard/DashboardLibraryView.swift')
-rw-r--r-- | Jel/Views/Dashboard/DashboardLibraryView.swift | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/Jel/Views/Dashboard/DashboardLibraryView.swift b/Jel/Views/Dashboard/DashboardLibraryView.swift index 98c92c0..00f0e68 100644 --- a/Jel/Views/Dashboard/DashboardLibraryView.swift +++ b/Jel/Views/Dashboard/DashboardLibraryView.swift @@ -14,7 +14,12 @@ struct DashboardLibraryView: View { @StateObject var authState: AuthStateController = AuthStateController.shared @State var libraries: [BaseItemDto] = [] + @State var loading: Bool = true var body: some View { + if loading { + ProgressView() + .progressViewStyle(.circular) + } ScrollView(.horizontal, showsIndicators: false) { HStack { ForEach(libraries) {library in @@ -22,9 +27,10 @@ struct DashboardLibraryView: View { NavigationLink { LibraryDetailView(library: library) } label: { - LibraryIconView(library: library, height: 200) + LibraryIconView(library: library, height: 150) .padding() } + .buttonStyle(PlainButtonStyle()) } } } @@ -36,11 +42,11 @@ struct DashboardLibraryView: View { if let results = try await jellyfinClient.send(request).value.items { libraries = results } + loading = false } catch { } } - } - } + }} } //#Preview { |