diff --git a/JellyfinPlayer/ContinueWatchingView.swift b/JellyfinPlayer/ContinueWatchingView.swift index cb565758..0728f566 100644 --- a/JellyfinPlayer/ContinueWatchingView.swift +++ b/JellyfinPlayer/ContinueWatchingView.swift @@ -109,7 +109,7 @@ struct ContinueWatchingView: View { if(resumeItems.count != 0) { VStack(alignment: .leading) { ScrollView(.horizontal, showsIndicators: false) { - HStack() { + LazyHStack() { if(isLoading == false) { Spacer().frame(width:16) ForEach(resumeItems, id: \.Id) { item in diff --git a/JellyfinPlayer/LatestMediaView.swift b/JellyfinPlayer/LatestMediaView.swift index 9d572176..44f91a87 100644 --- a/JellyfinPlayer/LatestMediaView.swift +++ b/JellyfinPlayer/LatestMediaView.swift @@ -84,7 +84,7 @@ struct LatestMediaView: View { var body: some View { ScrollView(.horizontal, showsIndicators: false) { - HStack() { + LazyHStack() { Spacer().frame(width:18) ForEach(resumeItems, id: \.Id) { item in NavigationLink(destination: ItemView(item: item)) { diff --git a/JellyfinPlayer/LibraryView.swift b/JellyfinPlayer/LibraryView.swift index 570b9ad5..77aae1bf 100644 --- a/JellyfinPlayer/LibraryView.swift +++ b/JellyfinPlayer/LibraryView.swift @@ -33,8 +33,6 @@ struct LibraryView: View { @State private var url: String = ""; @State private var closeSearch: Bool = false; - var gridItems: [GridItem] = [GridItem(.adaptive(minimum: 150, maximum: 400))] - init(prefill: String?, names: [String: String], libraries: [String]) { _prefill_id = State(wrappedValue: prefill ?? "") _library_names = State(wrappedValue: names) @@ -166,91 +164,93 @@ struct LibraryView: View { _tracks.wrappedValue = [] for _ in (0..