mirror of
https://github.com/yattee/yattee.git
synced 2025-08-06 10:44:06 +00:00
Fix for loading subscriptions
This commit is contained in:
@@ -208,7 +208,10 @@ struct VideoView: View {
|
||||
image
|
||||
.resizable()
|
||||
} placeholder: {
|
||||
ProgressView()
|
||||
HStack {
|
||||
ProgressView()
|
||||
.frame(minWidth: 0, maxWidth: .infinity, minHeight: 0, maxHeight: .infinity)
|
||||
}
|
||||
}
|
||||
} else {
|
||||
Image(systemName: "exclamationmark.square")
|
||||
|
@@ -12,7 +12,13 @@ struct SubscriptionsView: View {
|
||||
var body: some View {
|
||||
VideosView(videos: store.collection)
|
||||
.onAppear {
|
||||
resource.loadIfNeeded()
|
||||
if let home = InvidiousAPI.shared.home.loadIfNeeded() {
|
||||
home.onSuccess { _ in
|
||||
resource.loadIfNeeded()
|
||||
}
|
||||
} else {
|
||||
resource.loadIfNeeded()
|
||||
}
|
||||
}
|
||||
.refreshable {
|
||||
resource.load()
|
||||
|
@@ -2,6 +2,10 @@ import Siesta
|
||||
import SwiftUI
|
||||
|
||||
struct WatchNowView: View {
|
||||
init() {
|
||||
InvidiousAPI.shared.home.loadIfNeeded()
|
||||
}
|
||||
|
||||
var body: some View {
|
||||
ScrollView(.vertical, showsIndicators: false) {
|
||||
VStack(alignment: .leading, spacing: 0) {
|
||||
|
Reference in New Issue
Block a user