Contact Detail & Edit
Feature Detail
Description
Contact Detail & Edit provides a screen for viewing and modifying a contact's full profile: personal information, organizational memberships, linked peer mentor relationship, and activity history. The detail view is read-optimized for fast access during activity logging. The edit screen applies field-level validation and optimistic mutations with automatic rollback on API failure. All interactive elements meet WCAG 2.2 AA including screen-reader labels, inline error messages, and keyboard navigation through all form fields.
Sources & reasoning
Line 285 explicitly names "Contact detail, edit, and peer mentor profile screens" as mobile app screens. Line 311 places contact management in the Fase 1 MVP scope. Full CRUD on contacts is implicit in any usable contact management system and is a hard dependency for activity logging. Phase 1 maps to MVP by ordinal rule.
-
docs/source/likeperson.md · line 285Contact detail, edit, and peer mentor profile screens
-
docs/source/likeperson.md · line 311Kontaktliste og likepersonsoversikt
Analysis
Accurate contact records are foundational to Bufdir-compliant activity reporting - every logged activity references a contact, and incorrect data propagates into organizational reports. The in-app edit capability lets coordinators correct contact information in the field without routing changes through the admin portal, reducing administrative bottlenecks and improving data quality. NHF's duplicate-activity detection and Barnekreftforeningen's caregiver workflows both depend on contacts being precisely maintained. Optimistic mutations with rollback also directly support the offline-first architecture requirement described in the mobile app specification.
Two coordinated Flutter screens sharing a ContactRepository Riverpod provider backed by Drift. The detail screen uses read-only widgets built from the design token system for consistent WCAG-compliant styling. The edit screen applies FormField-level validation with inline error text satisfying WCAG 3.3.1. Optimistic mutations write to the local Drift database immediately and enqueue a PATCH to the mutation outbox; on API error the local record is rolled back and a toast shown. Role guards built with the Role Guard Service prevent peer mentors from accessing coordinator-only fields. All fields must have semantic accessibility labels and ≥24×24 px touch targets.
Components (43)
Shared Components
These components are reused across multiple features
Service Layer (11)
Data Layer (23)
Infrastructure (7)
User Stories
No user stories have been generated for this feature yet.