Assigned Contacts List
Component Detail
Description
Scrollable list section displaying the contacts currently assigned to this peer mentor. Each row shows contact name, assignment date, and last activity date. Tapping a row navigates to the Contact Detail screen. For Blindeforbundet, also shows open assignment count and follow-up deadline.
assigned-contacts-list
Summaries
The Assigned Contacts List gives coordinators immediate visibility into a mentor's current caseload — who they are working with, how recently there has been activity, and for Blindeforbundet, whether any follow-up deadlines are at risk. This transforms a mentor's profile from a static record into an actionable coordination tool, reducing the time coordinators spend cross-referencing separate contact lists. By surfacing organization-specific metadata such as open assignment counts and deadlines for Blindeforbundet, the platform demonstrates deep configurability to partner organizations, strengthening retention and justifying premium positioning relative to generic case management alternatives.
Low complexity for the base implementation, but the Blindeforbundet-specific conditional rendering adds a branching requirement that must be tested separately. The `organizationId` prop drives this conditional — ensure the org identification contract is consistent with how other components resolve organization context. Navigation to the Contact Detail screen on row tap introduces a cross-feature dependency: the Contact Detail screen must exist or have a defined placeholder before integration testing. Empty state design must be confirmed with UX before development.
Test matrix should cover: populated list, empty list, Blindeforbundet org (with deadline badge), non-Blindeforbundet org (without badge), and row tap navigation. Low delivery risk overall.
Stateless Flutter widget rendering a `ListView` from `List
`_buildEmptyState` should return a centered illustration or text consistent with other empty states in the app. For long lists, consider `ListView.builder` for lazy rendering. The `AssignedContact` model must expose `name`, `assignmentDate`, `lastActivityDate`, and optionally `openAssignmentCount` and `followUpDeadline` for Blindeforbundet. Widget tests: mock contact lists, verify row count, verify conditional badge presence/absence by org ID.
Responsibilities
- Render list of assigned contacts with key metadata
- Navigate to contact detail on row tap
- Show Blindeforbundet-specific open assignment count and deadline badge
- Display empty state when no contacts assigned
Interfaces
AssignedContactsList({required List<AssignedContact> contacts, required Function(String contactId) onContactTap, required String organizationId})
build(BuildContext context)
_buildContactRow(AssignedContact contact)
_buildEmptyState()