Skip to content

Commit d99277e

Browse files
authored
fixing multi-OS builds (#25)
1 parent 8dc2eee commit d99277e

File tree

2 files changed

+13
-1
lines changed

2 files changed

+13
-1
lines changed

Sources/RadiantKit/ViewExtensions/SingleWindowView.swift

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,5 +76,17 @@
7676
}
7777
}
7878
}
79+
#else
80+
extension WindowGroup {
81+
/// Initializes a new instance of the `WindowGroup` with a single window
82+
/// view.
83+
/// - Parameter _: The type of the `SingleWindowView`.
84+
@MainActor
85+
public init(singleOf _: Content.Type) where Content: SingleWindowView {
86+
self.init {
87+
Content()
88+
}
89+
}
90+
}
7991
#endif
8092
#endif

Sources/RadiantProgress/ProgressOperationProperties.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
// OTHER DEALINGS IN THE SOFTWARE.
2828
//
2929

30-
#if canImport(Observation) && (os(macOS) || os(iOS))
30+
#if canImport(Observation)
3131

3232
public import Foundation
3333

0 commit comments

Comments
 (0)