From 45741a51601a3075ad825795be2dc36a637ac742 Mon Sep 17 00:00:00 2001 From: Christian Cleberg Date: Sat, 25 Jul 2026 11:45:32 -0500 Subject: fix: point Rate at the App Store and drop the empty Legal section (#56) - Rate DomainDig now opens the App Store write-review URL (AppLinks.writeReview, derived from the real app id) instead of the in-app StoreKit prompt, so an explicit tap always reaches the review composer. Drops the now-unused StoreKit import and requestReview environment. - The copyright line moves into the "Support the App" section footer, removing the empty Section content closure SonarCloud flagged (swift:S1186). --- DomainDig/AppInfoView.swift | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) (limited to 'DomainDig/AppInfoView.swift') diff --git a/DomainDig/AppInfoView.swift b/DomainDig/AppInfoView.swift index 749c066..055fe46 100644 --- a/DomainDig/AppInfoView.swift +++ b/DomainDig/AppInfoView.swift @@ -1,14 +1,11 @@ -import StoreKit import SwiftUI /// Settings → App Info. Shows app/build metadata and links out to docs, source, /// privacy, support, and the App Store. The actionable rows are driven by a /// single declarative `AppInfoRow` model so titles, icons, and destinations live -/// in one place; only the Rate and Share rows are special-cased (a StoreKit -/// action and a `ShareLink` view, respectively). +/// in one place; only the Share row is special-cased (a `ShareLink` view). struct AppInfoView: View { @Environment(\.openURL) private var openURL - @Environment(\.requestReview) private var requestReview @State private var cloudSyncService = CloudSyncService.shared @State private var activeSheet: AppInfoSheet? @@ -29,20 +26,20 @@ struct AppInfoView: View { ForEach(supportRows) { row($0) } } - Section("Support the App") { + Section { Button { - requestReview() + openURL(AppLinks.writeReview) } label: { Label("Rate DomainDig", systemImage: "star") } + .accessibilityHint("Opens the App Store") ShareLink(item: AppLinks.appStoreListing) { Label("Share DomainDig", systemImage: "square.and.arrow.up") } .accessibilityHint("Opens the share sheet") - } - - Section { + } header: { + Text("Support the App") } footer: { Text(AppLinks.copyright) .frame(maxWidth: .infinity, alignment: .center) -- cgit v1.2.3