high priority low complexity frontend pending frontend specialist Tier 0

Acceptance Criteria

CoordinatorEscalationNotificationCard is a StatelessWidget with typed constructor parameters: peerMentorName (String), elapsedDays (int), assignmentContextSummary (String), assignmentId (String), and onNavigate (VoidCallback)
The card uses a visually distinct accent colour (e.g., warning amber or error red from design tokens) that differs from ReminderNotificationCard's accent colour
An escalation icon (e.g., warning triangle or bell-with-exclamation) is displayed alongside the title — the icon must be meaningful independent of colour (shape and label provide the distinction)
The peer mentor's name is displayed as a labelled field (e.g., 'Peer Mentor: [Name]') in a readable typographic style
Elapsed days and assignment context summary are displayed using the same layout conventions as ReminderNotificationCard for consistency
A CTA button labeled 'View Assignment' navigates to the assignment detail screen via the onNavigate callback
All spacing, colours, radii, and typography are sourced from design tokens — no hardcoded values
WCAG 2.2 AA contrast is met for all text and interactive elements
Semantic label on the escalation icon reads 'Escalated reminder' (or equivalent) for screen readers
Widget tests confirm the card renders peerMentorName, elapsedDays, assignmentContextSummary, escalation icon, and CTA without layout overflow at 375px and 414px widths

Technical Requirements

frameworks
Flutter
Dart
data models
EscalationNotification (peerMentorName, elapsedDays, assignmentContextSummary, assignmentId)
performance requirements
StatelessWidget — const-constructible when all parameters are compile-time constants
Build method completes in a single frame with no async operations
security requirements
peerMentorName must be rendered as plain text — no HTML rendering
Widget must only be reachable by users with coordinator role — enforce at routing layer, not in the widget itself
ui components
Card container (project AppCard or equivalent)
Escalation icon (Icon widget with Semantics label)
Peer mentor name labelled field (Text widgets)
Elapsed days label
Assignment context summary (maxLines: 2, overflow: ellipsis)
CTA AppButton

Execution Context

Execution Tier
Tier 0

Tier 0 - 440 tasks

Implementation Notes

Extract shared card structure (elapsed days, summary, CTA) into a private helper widget or mixin shared between ReminderNotificationCard and CoordinatorEscalationNotificationCard to avoid duplication — but only if the shared structure is stable. If the two cards are likely to diverge further, keep them independent. The escalation icon must communicate urgency through both shape and colour: use a warning-triangle (`Icons.warning_amber_rounded`) not just a colour change. Store the escalation accent colour as a named design token (e.g., `AppColors.escalationAccent`) rather than referencing a raw colour value.

File location: `lib/features/notifications/widgets/coordinator_escalation_notification_card.dart`.

Testing Requirements

Widget tests using flutter_test: (1) all five data fields render correctly with sample inputs; (2) escalation icon is present in the widget tree; (3) CTA button tap invokes onNavigate; (4) no RenderFlex overflow at 375px and 414px widths; (5) the card is visually distinct from ReminderNotificationCard — verify the accent colour token used differs (check widget tree for the correct token reference). Optionally add a golden test to lock the escalation-specific visual treatment.

Epic Risks (2)
medium impact medium prob integration

The deep-link from the notification card to the assignment detail screen depends on the assignment detail route being stable and accepting an assignment ID parameter. If the routing contract is undocumented or changes during parallel development, the CTA will silently navigate to a fallback screen.

Mitigation & Contingency

Mitigation: Confirm the assignment detail route path and parameter contract with the team building or maintaining that screen before implementing the CTA. Add an integration test that asserts navigating from a mock notification card with a known assignment ID lands on the correct route.

Contingency: If the route is unstable, implement the deep-link as a late-bound string resolved from a central route registry, allowing the target route to be updated without changing the notification card.

medium impact medium prob technical

Visually distinguishing escalation cards from standard reminder cards using colour alone fails WCAG 1.4.1 (use of colour). Blindeforbundet users relying on screen readers must receive equivalent contextual information through semantics, not just visual styling.

Mitigation & Contingency

Mitigation: Use both colour and an icon/label difference to distinguish card types. Add explicit Semantics widgets with descriptive labels ('Escalation alert: peer mentor has not responded') so screen readers announce the type without visual context.

Contingency: If accessibility review flags the distinction, add a text badge ('Escalation') alongside the visual treatment as a code-change-only fix with no schema or service impact.