Description
Add a "Privacy" section in the Settings screen allowing the user to change their consent at any time.
File to modify
- Existing Settings screen (search for
SettingsScreen.kt or similar)
Expected UI
Settings (gear icon)
└── Privacy (Card)
└── Anonymous Statistics
├── Description: "Help improve VRHub by sharing anonymous usage data..."
├── Toggle Switch: "Share anonymous statistics"
└── (if enabled) Green text: "✓ Your data is being shared anonymously"
Behavior
- The Switch reflects
ConsentPreferences.consentEnabled state (collected via stateIn in ViewModel)
onCheckedChange triggers ConsentPreferences.setConsentEnabled(...) and StatsCollector.updateConsent() to sync with the server
- On disable: cancel
StatsCollectionWorker
- On enable: enqueue
StatsCollectionWorker
Reference
docs/CLIENT_SPEC.md §6
docs/CLIENT_IMPLEMENTATION.md §6
Description
Add a "Privacy" section in the Settings screen allowing the user to change their consent at any time.
File to modify
SettingsScreen.ktor similar)Expected UI
Behavior
ConsentPreferences.consentEnabledstate (collected viastateInin ViewModel)onCheckedChangetriggersConsentPreferences.setConsentEnabled(...)andStatsCollector.updateConsent()to sync with the serverStatsCollectionWorkerStatsCollectionWorkerReference
docs/CLIENT_SPEC.md§6docs/CLIENT_IMPLEMENTATION.md§6