Skip to content

Commit

Permalink
Merge branch 'main' into gemmakbarlow/xcode-16-library-evolution
Browse files Browse the repository at this point in the history
  • Loading branch information
stephencelis authored Oct 9, 2024
2 parents d6ed958 + 16a27ab commit 805dfc9
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
3 changes: 3 additions & 0 deletions Sources/SwiftNavigation/ButtonState.swift
Original file line number Diff line number Diff line change
Expand Up @@ -321,6 +321,9 @@ extension ButtonState: Sendable where Action: Sendable {}
/// - button: Button state.
/// - action: An action closure that is invoked when the button is tapped.
@available(iOS 15, macOS 12, tvOS 15, watchOS 8, *)
#if compiler(>=6)
@MainActor
#endif
public init<Action>(_ button: ButtonState<Action>, action: @escaping (Action?) -> Void) {
self.init(
role: button.role.map(ButtonRole.init),
Expand Down
3 changes: 3 additions & 0 deletions Sources/SwiftUINavigation/Alert.swift
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,9 @@
/// dismisses the alert, and the action is fed to the `action` closure.
/// - handler: A closure that is called with an action from a particular alert button when
/// tapped.
#if compiler(>=6)
@MainActor
#endif
public func alert<Value>(
_ state: Binding<AlertState<Value>?>,
action handler: @escaping (Value?) -> Void = { (_: Never?) in }
Expand Down

0 comments on commit 805dfc9

Please sign in to comment.