From 08a68e513809cee6ff54d6cff2b2b07fa5abf56e Mon Sep 17 00:00:00 2001 From: Neil Clayton Date: Thu, 25 Jul 2024 12:29:46 +1200 Subject: [PATCH] - needs @MainActor for earlier xcode --- Sources/KeyboardShortcuts/SwiftUI+Extensions.swift | 1 + 1 file changed, 1 insertion(+) diff --git a/Sources/KeyboardShortcuts/SwiftUI+Extensions.swift b/Sources/KeyboardShortcuts/SwiftUI+Extensions.swift index 236c1799..b12d7e6c 100644 --- a/Sources/KeyboardShortcuts/SwiftUI+Extensions.swift +++ b/Sources/KeyboardShortcuts/SwiftUI+Extensions.swift @@ -9,6 +9,7 @@ import Carbon // Provides a SwiftUI like wrapper function, that feels the same as the normal SwiftUI .keyboardShortcut view extension @available(macOS 12.3, *) extension View { + @MainActor public func keyboardShortcut(_ shortcutName: KeyboardShortcuts.Name) -> some View { KeyboardShortcutView(shortcutName: shortcutName) { self