Adding some size fixing (#709)

This commit is contained in:
Max Goedjen 2025-09-14 14:48:22 -07:00 committed by GitHub
parent d7f8d5e56b
commit e8cdcdfb7f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 8 additions and 3 deletions

View File

@ -9,13 +9,13 @@ struct Secretive: App {
@Environment(\.agentStatusChecker) var agentStatusChecker @Environment(\.agentStatusChecker) var agentStatusChecker
@Environment(\.justUpdatedChecker) var justUpdatedChecker @Environment(\.justUpdatedChecker) var justUpdatedChecker
@AppStorage("defaultsHasRunSetup") var hasRunSetup = false
@SceneBuilder var body: some Scene { @SceneBuilder var body: some Scene {
WindowGroup { WindowGroup {
ContentView() ContentView()
.environment(EnvironmentValues._secretStoreList) .environment(EnvironmentValues._secretStoreList)
.onReceive(NotificationCenter.default.publisher(for: NSApplication.didBecomeActiveNotification)) { _ in .onReceive(NotificationCenter.default.publisher(for: NSApplication.didBecomeActiveNotification)) { _ in
@AppStorage("defaultsHasRunSetup") var hasRunSetup = false
guard hasRunSetup else { return } guard hasRunSetup else { return }
agentStatusChecker.check() agentStatusChecker.check()
if agentStatusChecker.running && justUpdatedChecker.justUpdatedBuild { if agentStatusChecker.running && justUpdatedChecker.justUpdatedBuild {
@ -32,10 +32,12 @@ struct Secretive: App {
WindowGroup(id: String(describing: IntegrationsView.self)) { WindowGroup(id: String(describing: IntegrationsView.self)) {
IntegrationsView() IntegrationsView()
} }
.windowResizability(.contentMinSize)
WindowGroup(id: String(describing: AboutView.self)) { WindowGroup(id: String(describing: AboutView.self)) {
AboutView() AboutView()
} }
.windowStyle(.hiddenTitleBar) .windowStyle(.hiddenTitleBar)
.windowResizability(.contentSize)
} }
} }

View File

@ -85,7 +85,9 @@ struct SetupView: View {
integrations = true integrations = true
}, content: { }, content: {
IntegrationsView() IntegrationsView()
.frame(minWidth: 500, minHeight: 400)
}) })
.fixedSize(horizontal: false, vertical: true)
} }
} }

View File

@ -32,6 +32,7 @@ struct ToolConfigurationView: View {
selectedSecret = created selectedSecret = created
} }
} }
.fixedSize()
} }
} }
} }

View File

@ -33,7 +33,7 @@ struct AboutViewContent: View {
Button(.aboutBuildLogButton) { Button(.aboutBuildLogButton) {
openURL(Bundle.main.buildLog) openURL(Bundle.main.buildLog)
} }
.normalButton() .normalButton()
} }
} }
} }

View File

@ -16,7 +16,7 @@ struct ContentView: View {
@Environment(\.updater) private var updater @Environment(\.updater) private var updater
@Environment(\.agentStatusChecker) private var agentStatusChecker @Environment(\.agentStatusChecker) private var agentStatusChecker
@AppStorage("defaultsHasRunSetup") private var hasRunSetup = false @State private var hasRunSetup = false
@State private var showingCreation = false @State private var showingCreation = false
@State private var showingAppPathNotice = false @State private var showingAppPathNotice = false
@State private var runningSetup = false @State private var runningSetup = false