feat: Resolving concurrency warnings

This commit is contained in:
2024-06-11 10:34:19 -04:00
parent e07df0e426
commit bf2e65fb8f
15 changed files with 156 additions and 130 deletions

View File

@@ -1,5 +1,6 @@
import SwiftUI
@MainActor
public protocol TextLabelStyle {
associatedtype Body: View
@@ -28,6 +29,7 @@ public struct TextLabelConfiguration {
public let label: TextLabelConfiguration.Label
}
@MainActor
public struct AnyTextLabelStyle: TextLabelStyle {
private var _makeBody: (Configuration) -> AnyView
@@ -57,6 +59,7 @@ public struct AnyTextLabelStyle: TextLabelStyle {
}
}
@MainActor
public struct AutomaticTextLabelStyle: TextLabelStyle {
public func makeBody(configuration: Configuration) -> some View {
configuration.label