As an identity holder, I want to tap a notification and land on the thread or document it is about, so that I can read it in context and answer on the spot.
Situation
My Activity inbox shows a row such as "Ana replied to you in Hypermedia" with an unread dot. I may have been reading something else in the Read tab, possibly on another site.
What I do
Tap the row.
Read the thread or document that opens in the Read tab.
Reply if I want to.
Go back to return to what Read showed before, or tap the Activity tab to return to the list.
What I should see
The app switches to the Read tab.
A notification about a comment opens that conversation's thread from its first comment, with the reply field at the bottom.
A notification about a document, such as "updated", opens the document.
The row is marked read as I open it: back in Activity its dot is gone and the summary has gone down by one, for example from "2 unread" to "1 unread".
Rows I have already read open the same way.
The Activity tab still shows the inbox where I left it.
Back in Read returns to the page that was open there before I tapped the notification.
The thread is loaded from my own server even if Read was showing another site; going back restores that other site and its context.
A reply I send from that thread is published to my own server.
The thread's top line shows the document's title, so I can open the whole document.
When something goes wrong
If the thread or document cannot be loaded, the Read tab shows the reason with "Retry"; tapping it loads again. The notification is still marked read.
If marking the row read fails, the page still opens. Back in Activity a red line gives the reason, for example "Notification server not responding (hyper.media).", and the dot remains. Tapping the row again retries.
Not included
The thread opens at its first comment. It does not scroll to or highlight the particular reply the notification was about (Activity model).
A row cannot be marked unread again, and cannot be deleted or archived.
There is no preview of the comment before opening (Activity tab screens).
Trace
Story US-ACT-02, status Shipped. These links are kept in step with the traceability matrix and with the "User stories" section of every page listed here.
Design
Page | Part it plays |
|---|---|
Where the row is tapped and where the dot clears | |
Where a comment notification lands | |
Where a document notification lands | |
The row as a full-width button with dot and chevron | |
The failure line with Retry on the landing screen | |
Activity into Read: select the tab, then open on its stack | |
An Activity thread uses the configured server and Back restores the covered context | |
Each tab keeps its own stack | |
The thread is pushed on the Read stack | |
The cross-tab edge from Activity to Read | |
Opening is reading: Activity does not copy the reader | |
Failure with Retry on the landing screen; the red action error in the inbox | |
Rows that navigate carry a chevron | |
The unread dot |
Implementation
Page | Part it plays |
|---|---|
The row button and activityOpenRow | |
notificationHref: thread root for comments, document link otherwise; isRead | |
activityApply mark-event-read and the committed snapshot | |
The signed write | |
The signed notify envelope | |
The mark-event-read action | |
select(nav, "read") then go; the from=activity marker | |
activityChanged and activitySaveError | |
readContextRef treats an Activity thread as a configured-server context | |
readContextServer and how Back restores it | |
The thread is loaded from the context server | |
The thread screen that opens | |
The inbox row test and the Activity thread test | |
The "thread" scenario of the fixture | |
The local server that serves the synthetic thread | |
Row links and read-state unit tests |
Code
File | What |
|---|---|
the notification row button, unread dot and chevron | |
activityOpenRow | |
readContextRef: an Activity thread starts a configured-server context | |
activityChanged, activityReady, activitySaveError | |
isRead and notificationHref | |
activityApply | |
notificationRequest | |
loadThread |
Tests
File | What it checks |
|---|---|
activity: grouped days, unread dots, mark all read and push a document | |
Activity thread fetch and reply use the configured server, not the covered document origin | |
doc rows use Read routes and replies use the thread root; mark-event-read and mark-all-read return canonical snapshots |
Do you like what you are reading? Subscribe to receive updates.
Unsubscribe anytime