arch-atlas

Notifications Screen

views/notifications_screen.dart

presentation

Overview

Lists all notifications with type-coded icons and colors, an unread-count chip in the header, a 'Mark all as read' action, and per-row tap to navigate or open detail.

User Flow

  1. Watches notificationsControllerProvider for state.
  2. Pull-to-refresh calls refresh.
  3. Row tap fires markAsRead and navigates based on type / template (orders → /orders/:id; messages → /messages).
  4. 'Mark all read' calls markAllAsRead.

Cases & Edge Cases

  • Empty state renders illustration + 'No notifications yet'.
  • Type colors come from the model extension — keep palette in sync with theming.
  • Long-press on a row reveals a dismiss action that calls deleteNotification (local-only).

Code References

  • lib/src/features/shared/notifications/views/notifications_screen.dart
  • lib/src/features/shared/notifications/views/notification_detail_screen.dart

API Calls

Empty — fill this in later. Open the manifest and add content here.

Notes

The unread badge consumers (e.g. home bell icon) should ref.watch the state.unreadCount derived getter, not the full list.