diff --git a/Outpost.xcodeproj/xcshareddata/xcschemes/Outpost.xcscheme b/Outpost.xcodeproj/xcshareddata/xcschemes/Outpost.xcscheme new file mode 100644 index 0000000..cf7bbda --- /dev/null +++ b/Outpost.xcodeproj/xcshareddata/xcschemes/Outpost.xcscheme @@ -0,0 +1,101 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Outpost/Features/About/TipJarView.swift b/Outpost/Features/About/TipJarView.swift index ee73611..2bf7902 100644 --- a/Outpost/Features/About/TipJarView.swift +++ b/Outpost/Features/About/TipJarView.swift @@ -9,7 +9,7 @@ struct TipJarView: View { @State private var store = TipJarStore() var body: some View { - VStack(alignment: .leading, spacing: 8) { + VStack(spacing: 8) { Text("Support Outpost") .font(.callout.weight(.semibold)) diff --git a/Outpost/Features/Account/AccountFooter.swift b/Outpost/Features/Account/AccountFooter.swift index e4c2033..885a615 100644 --- a/Outpost/Features/Account/AccountFooter.swift +++ b/Outpost/Features/Account/AccountFooter.swift @@ -1,5 +1,6 @@ #if os(macOS) import SwiftUI +import StoreKit import OutlineKit /// Uses a plain `Button` + `.popover` rather than `Menu`. A `Menu` whose label @@ -9,20 +10,13 @@ import OutlineKit struct AccountFooter: View { @Environment(SessionStore.self) private var session @Environment(AppNavigation.self) private var navigation - @Environment(\.openURL) private var openURL + @Environment(\.requestReview) private var requestReview @AppStorage("outpost.appearance") private var appearance: AppAppearance = .system @AppStorage(CachingOutlineAPIClient.offlineModeDefaultsKey) private var isOfflineModeEnabled = false @State private var isMenuPresented = false @State private var isShowingLogoutConfirmation = false @State private var isShowingProfile = false - private let repositoryURL = URL(string: "https://git.psmattas.com/psmattas/Outpost")! - private let issuesURL = URL(string: "https://git.psmattas.com/psmattas/Outpost/issues")! - - private var apiDocumentationURL: URL? { - session.serverURL?.appendingPathComponent("developers") - } - var body: some View { Button { isMenuPresented = true @@ -62,16 +56,10 @@ struct AccountFooter: View { private var menuContent: some View { VStack(alignment: .leading, spacing: 2) { - menuItem("Documentation") { openURL(repositoryURL) } - if let apiDocumentationURL { - menuItem("API Documentation") { openURL(apiDocumentationURL) } - } - menuItem("Changelog") { openURL(repositoryURL) } - - Divider() - - menuItem("Send Us Feedback") { openURL(issuesURL) } - menuItem("Report a Bug") { openURL(issuesURL) } + // Apple's own review/feedback prompt — there's no separate + // native channel for "bug" vs. "feedback", so one button covers + // both. + menuItem("Leave Us Feedback") { requestReview() } Divider() @@ -101,6 +89,14 @@ struct AccountFooter: View { // as "Invalid attempt to open a new transaction during CA // commit") — letting the popover's dismissal finish first avoids it. menuItem("Settings…") { Task { @MainActor in navigation.isShowingSettings = true } } + // Same deferred-Task reasoning as Settings… above — this also + // sets isShowingSettings synchronously. + menuItem("Support Outpost") { + Task { @MainActor in + navigation.selectedSettingsSection = .about + navigation.isShowingSettings = true + } + } Divider()