Onboarding: prompt permissions in context + data page

Location and network fetches no longer fire at launch before onboarding
reaches the relevant step: foreground tracking and the first refresh are
gated behind onboarding completion (scenePhase no longer starts tracking
while the cover is up, and onAppear defers its fetch until after
finish). A new Data page sits just before 'You're all set': it probes
the FuelBoard Relay, which surfaces the iOS Local Network permission
prompt in context (NSLocalNetworkUsageDescription added), verifies
connectivity, and offers Open Settings/Check again on denial. Onboarding
is now 5 pages: Welcome, Location, Notifications, Data, Done. 35 tests
pass.
This commit is contained in:
FuelBoard Contributor
2026-08-12 11:59:07 +01:00
parent 002d7f63e2
commit 20589f41fe
3 changed files with 143 additions and 15 deletions
+2
View File
@@ -26,6 +26,8 @@
<string>FuelBoard uses your location to find the cheapest nearby petrol stations.</string>
<key>NSLocationAlwaysAndWhenInUseUsageDescription</key>
<string>FuelBoard uses Always location to alert you when you approach the cheapest station nearby.</string>
<key>NSLocalNetworkUsageDescription</key>
<string>FuelBoard connects to the FuelBoard Relay on your local network to download the latest fuel prices.</string>
<key>UIBackgroundModes</key>
<array>
<string>location</string>