From 2c608ed9cb11f3e835f577994b5627b9b7910f4f Mon Sep 17 00:00:00 2001 From: Christian Cleberg Date: Mon, 20 Jul 2026 19:14:04 -0500 Subject: feat(a11y): unlock light mode and add appearance preference (#21 phase 2) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Removes the 16 scattered .preferredColorScheme(.dark) calls and the one .toolbarColorScheme, and applies appearance in exactly one place — the WindowGroup in DomainDigApp. Re-applying per view is what let the lock spread across eight files unnoticed until light mode was unreachable. Adds AppAppearance (System / Light / Dark) in @AppStorage, exposed under Settings > Display next to Density. Honouring the system setting and offering an override is one key, and it keeps the deliberate dark aesthetic reachable for anyone who wants it. Also replaces .secondary with AppTextSecondary across 191 sites. iOS's own secondaryLabel is 3.29:1 on a light card — below AA — which never showed while the app was locked to dark, where the same colour reads 6.32:1. Unlocking light mode is precisely what exposed it, so it belongs here rather than in a later phase: without it, light mode would ship with body text under 4.5:1 app-wide. Dark mode reports 18 findings, unchanged from phase 1 — no regression from unlocking. Light mode reports 21. The three extra are iOS-rendered Section headers (TIER, PREFERENCES, SERVICES) using the system's grey; overriding system header styling across every section to gain ~0.3:1 on decorative labels is a poor trade and is left alone. Two long-standing Settings contrast findings are now explained. They are the last rows of a section sitting under the translucent tab bar, so the audit measures text against a blended background — confirmed by screenshot, present in dark mode since phase 0, and standard iOS scroll-under behaviour rather than a defect. --- DomainDig/DomainCompareView.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'DomainDig/DomainCompareView.swift') diff --git a/DomainDig/DomainCompareView.swift b/DomainDig/DomainCompareView.swift index 90ee5b1..8219fa7 100644 --- a/DomainDig/DomainCompareView.swift +++ b/DomainDig/DomainCompareView.swift @@ -38,7 +38,7 @@ struct DomainCompareView: View { Section { Text("Choose two different domains to compare.") .font(.callout) - .foregroundStyle(.secondary) + .foregroundStyle(Color(.appTextSecondary)) } } -- cgit v1.2.3