Skip to content

Commit

Permalink
🐛 Fix frames not applied
Browse files Browse the repository at this point in the history
  • Loading branch information
KrLite committed Dec 17, 2024
1 parent f4685fa commit 2944ea3
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions Sources/Luminare/Main Window/LuminareWindow.swift
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ public class LuminareWindow: NSWindow {
/// - content: the content view of the window, wrapped in a ``LuminareView``.
public init(
blurRadius: CGFloat? = nil,
minFrame _: CGSize = .init(width: 100, height: 100),
maxFrame _: CGSize = .init(width: CGFloat.infinity, height: CGFloat.infinity),
minFrame: CGSize = .init(width: 100, height: 100),
maxFrame: CGSize = .init(width: CGFloat.infinity, height: CGFloat.infinity),
content: @escaping () -> some View
) {
self.initializationTime = .now
Expand All @@ -34,6 +34,8 @@ public class LuminareWindow: NSWindow {
let view = NSHostingView(
rootView: LuminareView(content: content)
.environment(\.luminareWindow, self)
.environment(\.luminareWindowMinFrame, minFrame)
.environment(\.luminareWindowMaxFrame, maxFrame)
)

contentView = view
Expand Down

0 comments on commit 2944ea3

Please sign in to comment.