mirror of
https://github.com/omnivore-app/omnivore.git
synced 2026-03-11 08:54:26 +00:00
Add MainActor to main views in iOS
This commit is contained in:
parent
392c2e2032
commit
57894754a6
4 changed files with 6 additions and 0 deletions
|
|
@ -23,6 +23,7 @@ struct AnimatingCellHeight: AnimatableModifier {
|
|||
#if os(iOS)
|
||||
private let enableGrid = UIDevice.isIPad || FeatureFlag.enableGridCardsOnPhone
|
||||
|
||||
@MainActor
|
||||
struct HomeFeedContainerView: View {
|
||||
@State var hasHighlightMutations = false
|
||||
@State var searchPresented = false
|
||||
|
|
@ -228,6 +229,7 @@ struct AnimatingCellHeight: AnimatableModifier {
|
|||
}
|
||||
}
|
||||
|
||||
@MainActor
|
||||
struct HomeFeedView: View {
|
||||
@EnvironmentObject var dataService: DataService
|
||||
@Binding var prefersListLayout: Bool
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@ import SwiftUI
|
|||
import Utils
|
||||
import Views
|
||||
|
||||
@MainActor
|
||||
struct HomeView: View {
|
||||
@State private var viewModel: HomeFeedViewModel
|
||||
|
||||
|
|
|
|||
|
|
@ -7,6 +7,7 @@ import Views
|
|||
|
||||
let appLogger = Logger(subsystem: "app.omnivore", category: "app-package")
|
||||
|
||||
@MainActor
|
||||
public struct RootView: View {
|
||||
@Environment(\.scenePhase) var scenePhase
|
||||
@StateObject private var viewModel = RootViewModel()
|
||||
|
|
@ -39,6 +40,7 @@ public struct RootView: View {
|
|||
}
|
||||
}
|
||||
|
||||
@MainActor
|
||||
struct InnerRootView: View {
|
||||
@EnvironmentObject var dataService: DataService
|
||||
@EnvironmentObject var authenticator: Authenticator
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@ import Utils
|
|||
import Views
|
||||
import WebKit
|
||||
|
||||
@MainActor
|
||||
struct WebReader: PlatformViewRepresentable {
|
||||
let item: LinkedItem
|
||||
let articleContent: ArticleContent
|
||||
|
|
|
|||
Loading…
Reference in a new issue