Skip to content

feat(mobile): an Inbox bell with the open count in the thread list's header - #888

Merged
Jacksondr5 merged 3 commits into
j5/mainfrom
j5code/inbox-bell
Nov 1, 2026
Merged

Jacksondr5 merged 3 commits into
j5/mainfrom
j5code/inbox-bell

Conversation

@Jacksondr5

@Jacksondr5 Jacksondr5 commented Nov 1, 2026 •

Copy link
Copy Markdown
Owner

Problem

Mobile's Inbox (#883, #887) has no way in. Nothing on the phone says something is waiting on the person, and the screen is reached only by deep link (#830; gap A9).

What changed

Part 4 of 4 for #830: a bell with the open count in the thread list's header, which opens the Inbox, as web's rail bell does.

  • Where: beside the filter in Android's thread-list toolbar, which Android's split view also uses for its sidebar header; and in the right toolbar of the thread list on iPhone and iPad (iOS draws the split view's sidebar header natively, through that same toolbar). Each layout has exactly one bell.
  • The count: the open count across every connected server (inboxCountSourcesAtom, built like web's). A count some server couldn't refresh is marked 3*, or ? when nothing is known. The spoken label says so ("Open inbox, last known 3 open; some environments could not be refreshed"). Badge and label come from one shared function, inboxBellPresentation in client-runtime/src/j5/inbox.ts, which web's bell now uses too; its inline copy is removed, and its test moved to client-runtime.
  • Open asks only. Web's bell also counts Crew add-member requests and seat approvals. Those come to mobile with Crews (Mobile: Crews and Fleet (decision deferred until the Crews rework lands) #836), so mobile's count can be lower than web's when a Crew request is waiting (the Captain agreed to this for now).
  • Updates: the count re-reads on the server's existing inbox signal, with no timer.
  • Upstream's symbol set has no plain bell on Android, so J5's BellGlyph draws Tabler's bell there and the SF Symbol bell on iOS (BellGlyph.tsx and BellGlyph.ios.tsx), rather than editing upstream's symbol map.

This completes #830 as scoped. Push notifications (#829) and Crew requests (#836) stay out.

UI changes

Android, base ba3dc4e770 (no bell) vs head 143628ecb1, cropped to the header, with the same viewport and theme:

State Before After
One open ask Android thread list header without a bell, before Android header bell showing 1 open ask, after
Several open asks Android thread list header without a bell, before Android header bell showing 3 open asks, after
Two servers: the counts sum Android thread list header without a bell, before Android header bell summing two servers' open asks, after
One server stopped: last-known count Android thread list header without a bell, before Android header bell showing a last-known 3* count with a server stopped, after
A whole-server Viewer: no badge Android thread list header without a bell, before Android Viewer's header bell with no badge, after
The Viewer's bell opens the Inbox new Android Viewer's Inbox with its not-shared notice, after

iPhone, base vs head 143628ecb1, cropped to the header:

State Before After
No open asks: the bell, no badge iPhone thread list header without a bell, before iPhone header bell with no badge, after
Open asks arriving live iPhone thread list header without a bell, before iPhone header bell showing the open count, after
After answering one in the Inbox iPhone thread list header without a bell, before iPhone header bell after an answer, count dropped, after
Server stopped: last-known count iPhone thread list header without a bell, before iPhone header bell showing a last-known 2* count, after
A whole-server Viewer: no badge iPhone thread list header without a bell, before iPhone Viewer's header bell with no badge, after
The Viewer's bell opens the Inbox new iPhone Viewer's Inbox with its not-shared notice, after

The iPhone shots of the owner's header show iOS's native scroll-edge blur, which is expected.

Android: the bell's count rises live as asks arrive, the bell opens the Inbox, and answering from web drops it from 3 to 2 while the header stays open.

Android-Inbox-bell-live-count-and-answer.mp4

Live testing

Verdict: PASS on Android and iPhone at 143628ecb1. The crew tester ran it (Sol 6.1) with real Claude Haiku 5.5 asks. Report: artifacts/test-reports/j5code-mobile-tester-sol/143628ecb1.md. The video was checked for a signed-out viewer (200 video/mp4).

  • Android:
    • With no asks, no badge. Real asks took it 0 → 1 → 2 → 3 live, without a refresh.
    • The bell opens the Inbox, and an answer from web took it 3 → 2 while the header stayed open (at dfa49be1e1, video).
    • At the head: two servers sum (2 + 1 = 3); a stopped server reads 3*, and the spoken label says last-known; a whole-server Viewer has no badge, and the bell opens the Inbox's "not shared with you".
  • iPhone at the head:
    • With no asks, no badge, and the count went 1 and 2 live.
    • Answering a third ask in the Inbox brings the count back to 2.
    • A stopped server reads 2*, with the last-known label.
    • The Viewer gets no badge, and the bell opens its not-shared Inbox.
  • React Compiler coverage passes (1026 tests).

Not exercised:

  • iPad and split view: verified by code reading only, since the rig has none. On iOS, the split view's sidebar header is native and drawn through WorkspaceToolbar, which now shows the bell on every iOS device.
  • Gaps on iPhone: two servers summing, and the iPhone header at 3 wasn't captured separately.
  • Unknown count (?): not exercised; the logic is shared and tested.
  • Other conditions: dark mode, landscape, large text and a physical phone.
  • Android live sequence: not repeated after dfa49be1e1. The later change only removed unused code from a branch no device draws.

Upstream impact

FORK.md case 102. One import and one or two lines in each of two files:

  • apps/mobile/src/features/home/ThreadListToolbar.tsx (Android toolbar, beside the filter, when a server is saved);
  • apps/mobile/src/features/workspace/WorkspaceToolbar.ios.tsx (a Toolbar.Custom on the thread list, iPhone and iPad);

Both are pinned in upstreamSeams.test.ts and listed in the file index.

Checklist

  • One concern: the Inbox bell and its count
  • Tests: inboxBellPresentation (count, none, marked-incomplete) in client-runtime, and the seams are pinned
  • UI changes: Android and iPhone before/after header crops above, and a video of the live count
  • Live testing: the section above says what is pending
  • Upstream-owned files: each recorded in FORK.md (case 102 and file-table rows) in this PR
  • Upstream product: no change to upstream's behaviour; J5's bell is added beside its controls
  • Surfaces: Android, iPhone and split view; every connected server; an unreadable server is marked. Web's bell keeps its look and now shares the text logic.
  • Docs: in the wave-2 docs PR (Mobile: Inbox, with a count, answering, and Crew requests #830 and Mobile: a way out of the "Who are you?" question #870)

Built by Claude Opus 5.5 in Claude Code (J5 crew seat builder-identity).

🤖 Generated with Claude Code

…header

The thread list's header gets a bell (#830, part 4 of 4) with the open count
across every connected server, marked when a server could not be read, that
opens the Inbox: beside the filter on Android, in the right toolbar on an iPhone,
and beside the filter in the split view's sidebar. It counts open asks only;
Crew requests join it with Crews. The bell's text is now one shared function,
used by web's bell too.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@vercel

vercel Bot commented Nov 1, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
j5-code Ready Ready Preview Nov 1, 2026 10:41pm UTC

Request Review

@coderabbitai

coderabbitai Bot commented Nov 1, 2026 •

Copy link
Copy Markdown

Warning

Review limit reached

  • Run on-demand review

This review includes 12 billable files and costs up to $3.00.

  • Ask an admin to make reviews automatic

Open in CodeRabbit

Reviews can continue after your included limit without a manual trigger. An admin must approve usage-based billing.

Or wait 6 minutes for your next included review.

Check out review usage here.

View limit details

Limit details: You’ve used all 3 included reviews currently available. Your 49 included PR review attempts over the past 7 days set your current allowance at 3 reviews per hour.

Learn how review limits work.

Review configuration:

Run configuration
Commits

Reviewing files that changed from the base of the PR and between ba3dc4e and 143628e.

Files selected for processing: 12
  • FORK.md
  • apps/mobile/src/features/home/ThreadListToolbar.tsx
  • apps/mobile/src/features/workspace/WorkspaceToolbar.ios.tsx
  • apps/mobile/src/j5/inbox/BellGlyph.ios.tsx
  • apps/mobile/src/j5/inbox/BellGlyph.tsx
  • apps/mobile/src/j5/inbox/InboxBell.tsx
  • apps/mobile/src/j5/inbox/inboxSources.ts
  • apps/mobile/src/j5/upstreamSeams.test.ts
  • apps/web/src/j5/a2a/HumanInboxBell.test.ts
  • apps/web/src/j5/a2a/HumanInboxBell.tsx
  • packages/client-runtime/src/j5/inbox.test.ts
  • packages/client-runtime/src/j5/inbox.ts
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

@github-actions github-actions Bot added the vouch:trusted PR author is trusted by repo permissions or the VOUCHED list. label Nov 1, 2026
@github-actions github-actions Bot added the size:L 100-499 effective changed lines (test files excluded in mixed PRs). label Nov 1, 2026

@Jacksondr5 Jacksondr5 left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Combined review: reviewer-opus and reviewer-sol (Claude Opus 5.5 and GPT Sol 6.1), head 69cea90

Both of us reviewed the PR independently and checked each finding against the source. One finding blocks merge.

Blocking

  1. iPad has no Inbox bell, and the sidebar seam never renders (found by reviewer-sol, confirmed by reviewer-opus).

    • The sidebar seam. On iOS, ThreadNavigationSidebar always renders NativeSidebarContainer with nativeChrome set (ThreadNavigationSidebar.tsx:112–127), and the pane returns early at :714. The non-native header that holds the new <InboxBell variant="sidebar" /> (:885) is therefore never reached on iOS. On Android the :853 branch renders ThreadListToolbar instead. So that seam is dead code in an upstream file.
    • The toolbar. On iPad, the thread list's chrome is WorkspaceRootContent's WorkspaceToolbar (WorkspaceRootScreen.tsx:227), which mounts for the threads tab on every iOS device. The new bell there is gated to deviceType === "phone" (WorkspaceToolbar.ios.tsx:194), so iPad and the Duo layouts get none.
    • Result. On iPad there is no way into the Inbox.

    Fix: show the toolbar bell wherever the iOS threads toolbar shows. The likely change is to drop && deviceType === "phone", or limit it to the layouts where the list is visible. Remove the unreachable ThreadNavigationSidebar.tsx seam, along with its seam-test row and its FORK case 102 and file-index mentions. The tester should then confirm exactly one bell on iPhone, iPad and Android.

Checked and fine

  • Bell text. inboxBellPresentation is web's old inline logic exactly: the badge is the count, count* or ?, and the label string is unchanged. Web's bell now uses it.
  • Count. inboxCountSourcesAtom uses the same source input. openCount already rereads on the inbox revision, so there's no timer, and #887's refreshAfterAnswer refreshes it too.
  • Android. The ThreadListToolbar seam, gated on hasConnections, covers the phone header and the Android sidebar.
  • Glyph. BellGlyph uses SF bell on iOS and Tabler's IconBell on Android, which is already a mobile dependency.
  • Scope. Crew requests stay out of the count until #836, as the Captain agreed.

iOS draws its split view's sidebar header natively, through the workspace
toolbar, so the bell there was limited to phones and the sidebar's own bell
never rendered on iPad. The toolbar now shows it on every iOS thread list; the
sidebar's bell is Android's split view.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

@Jacksondr5 Jacksondr5 left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Combined review: reviewer-opus and reviewer-sol, head dfa49be

Fixed: iPad's way in. WorkspaceToolbar.ios.tsx now shows the bell whenever selectedTab === "threads", on every iOS device, so iPad gets one bell in the toolbar its thread list actually uses.

Still blocking: the sidebar seam is dead code, and the new comment and FORK text describe it wrongly

ThreadNavigationSidebar.tsx:853 is Platform.OS === "android" ? <ThreadListToolbar … /> : <View …>. The <InboxBell variant="sidebar" /> at :886 sits in the non-Android branch:

  • Android always takes ThreadListToolbar, which already carries the bell through the ThreadListToolbar.tsx seam.
  • iOS returns at :714 (nativeChrome) before reaching :853.

So the bell is never drawn on any mobile platform. The comment's "Android's split view" is wrong, and so is FORK case 102's account of it. This can be seen from the source alone; no device run is needed.

Fix: remove the InboxBell import and JSX from ThreadNavigationSidebar.tsx, and remove its seam-test row and its FORK case 102 and file-index mentions. Case 102 then has two live seams, ThreadListToolbar.tsx and WorkspaceToolbar.ios.tsx. Nothing else needs to change.

Android's split view takes ThreadListToolbar and iOS draws the sidebar header
natively, so the sidebar's own bell never rendered. Two seams remain.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

@Jacksondr5 Jacksondr5 left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Combined review: reviewer-opus and reviewer-sol, head 143628e

Fixed. ThreadNavigationSidebar.tsx is byte-identical to trunk again: its diff against the merge base is empty. Its seam row and file-index row are gone, and FORK case 102 now names the two live seams: ThreadListToolbar.tsx (Android, including its split-view sidebar header) and WorkspaceToolbar.ios.tsx (iPhone and iPad). With the sidebar variant gone, InboxBell drops its variant prop and keeps the header look.

The panel has no open code findings. Before merge it still needs the tester's device run (one bell on Android and iPhone, with the count and the way into the Inbox; iPad has been verified by reading the code only, as the PR says) and green J5 CI.

@Jacksondr5
Jacksondr5 merged commit 085d69b into j5/main Nov 1, 2026
37 checks passed
@Jacksondr5
Jacksondr5 deleted the j5code/inbox-bell branch November 1, 2026 22:57

This branch was successfully deployed

1 active deployment
Preview — 143628ec Deployed Nov 1, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:L 100-499 effective changed lines (test files excluded in mixed PRs). vouch:trusted PR author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant