Design a Notification System
Problem Statement
Design a frontend notification system for user action items. The app should show notifications for things like expired passwords, friend activity, address updates, or other tasks the user may need to handle. Users should see an unread count, open a page with all notifications, and have a notification disappear when the related action item is completed. If the action item is not completed, the notification should persist.
This is a frontend system design prompt. Assume backend services can create notification records and know when action items are completed, but design the client experience, API contract, state model, and component architecture in enough detail that a frontend team could implement it.
This walkthrough follows the Product Architecture framework: requirements, data model, API design, high-level client architecture, and product trade-offs.
Separate two concepts: read means the user has seen the notification, while resolved means the underlying action item is complete. The prompt says unresolved action-item notifications should persist even after being viewed.