Add mobile email-approval bell (#6) (v0.1.0:102)

An admin-only bell in the mobile top bar (left of the camera) surfaces the
SAME pending email-capture proposals the web "Email Capture" panel and the
Matrix review room decide — a third surface over the existing endpoints, no
new backend.

- Count badge (iPhone-style) from a 45s poll of GET /api/activity/proposals;
  dim when there are none.
- Tap → card list of proposals → tap one → review screen (investor name,
  direction/date, subject, summary, editable proposed note) → Approve & log to
  grid (POST .../{id}/approve {note}) or Reject (POST .../{id}/dismiss).
- Bidirectional sync is automatic: an app decision flips the proposal status
  and the bot's poll redacts the Matrix thread; a Matrix/web decision drops the
  proposal from the pending list the bell polls, clearing the badge.
- No LLM round-trip (edit-then-approve, like the web panel). Mobile-gated
  (isMobile && admin) so the hidden desktop top bar never polls the endpoint.

Frontend-only; no schema, migration, or dependency change.
This commit is contained in:
Keysat
2026-06-20 15:36:56 -05:00
parent b04f83e1d1
commit 14c951de57
4 changed files with 161 additions and 4 deletions
+3 -2
View File
@@ -62,8 +62,9 @@ import { v_0_1_0_98 } from './v0.1.0.98'
import { v_0_1_0_99 } from './v0.1.0.99'
import { v_0_1_0_100 } from './v0.1.0.100'
import { v_0_1_0_101 } from './v0.1.0.101'
import { v_0_1_0_102 } from './v0.1.0.102'
export const versionGraph = VersionGraph.of({
current: v_0_1_0_101,
other: [v_0_1_0_39, v_0_1_0_40, v_0_1_0_41, v_0_1_0_42, v_0_1_0_43, v_0_1_0_44, v_0_1_0_45, v_0_1_0_46, v_0_1_0_47, v_0_1_0_48, v_0_1_0_49, v_0_1_0_50, v_0_1_0_51, v_0_1_0_52, v_0_1_0_53, v_0_1_0_54, v_0_1_0_55, v_0_1_0_56, v_0_1_0_57, v_0_1_0_58, v_0_1_0_59, v_0_1_0_60, v_0_1_0_61, v_0_1_0_62, v_0_1_0_63, v_0_1_0_64, v_0_1_0_65, v_0_1_0_66, v_0_1_0_67, v_0_1_0_68, v_0_1_0_69, v_0_1_0_70, v_0_1_0_71, v_0_1_0_72, v_0_1_0_73, v_0_1_0_74, v_0_1_0_75, v_0_1_0_76, v_0_1_0_77, v_0_1_0_78, v_0_1_0_79, v_0_1_0_80, v_0_1_0_81, v_0_1_0_82, v_0_1_0_83, v_0_1_0_84, v_0_1_0_85, v_0_1_0_86, v_0_1_0_87, v_0_1_0_88, v_0_1_0_89, v_0_1_0_90, v_0_1_0_91, v_0_1_0_92, v_0_1_0_93, v_0_1_0_94, v_0_1_0_95, v_0_1_0_96, v_0_1_0_97, v_0_1_0_98, v_0_1_0_99, v_0_1_0_100],
current: v_0_1_0_102,
other: [v_0_1_0_39, v_0_1_0_40, v_0_1_0_41, v_0_1_0_42, v_0_1_0_43, v_0_1_0_44, v_0_1_0_45, v_0_1_0_46, v_0_1_0_47, v_0_1_0_48, v_0_1_0_49, v_0_1_0_50, v_0_1_0_51, v_0_1_0_52, v_0_1_0_53, v_0_1_0_54, v_0_1_0_55, v_0_1_0_56, v_0_1_0_57, v_0_1_0_58, v_0_1_0_59, v_0_1_0_60, v_0_1_0_61, v_0_1_0_62, v_0_1_0_63, v_0_1_0_64, v_0_1_0_65, v_0_1_0_66, v_0_1_0_67, v_0_1_0_68, v_0_1_0_69, v_0_1_0_70, v_0_1_0_71, v_0_1_0_72, v_0_1_0_73, v_0_1_0_74, v_0_1_0_75, v_0_1_0_76, v_0_1_0_77, v_0_1_0_78, v_0_1_0_79, v_0_1_0_80, v_0_1_0_81, v_0_1_0_82, v_0_1_0_83, v_0_1_0_84, v_0_1_0_85, v_0_1_0_86, v_0_1_0_87, v_0_1_0_88, v_0_1_0_89, v_0_1_0_90, v_0_1_0_91, v_0_1_0_92, v_0_1_0_93, v_0_1_0_94, v_0_1_0_95, v_0_1_0_96, v_0_1_0_97, v_0_1_0_98, v_0_1_0_99, v_0_1_0_100, v_0_1_0_101],
})
+27
View File
@@ -0,0 +1,27 @@
import { VersionInfo } from '@start9labs/start-sdk'
// Mobile email-approval bell (#6) — a third surface over the EXISTING email-capture proposal
// flow, alongside the web "Email Capture" panel and the Matrix review room. Admin-only,
// frontend-only; no backend, schema, migration, or dependency change.
// - A bell in the mobile top bar (left of the camera) shows an iPhone-style count badge of
// pending proposals; dim when there are none.
// - Tap → a card list of proposals → tap one → a review screen (investor name, direction/date,
// subject, one-line summary, and the editable proposed note) → Approve & log to grid / Reject.
// - Reuses GET /api/activity/proposals + POST /api/activity/proposals/{id}/approve|dismiss
// (both require_admin). No LLM round-trip — edit-then-approve, exactly like the web panel.
// - Sync is automatic and bidirectional: deciding here flips the proposal status and the bot's
// poll redacts the Matrix thread; a Matrix- or web-side decision drops the proposal from the
// pending list the bell polls (every 45s), clearing the badge. Mobile-gated so the hidden
// desktop top bar never polls the admin endpoint.
export const v_0_1_0_102 = VersionInfo.of({
version: '0.1.0:102',
releaseNotes: {
en_US: [
'Email approvals on your phone: a bell in the mobile top bar shows how many captured-email',
'notes are waiting to be logged. Tap to review each one (investor + the proposed note),',
'edit it if needed, then Approve to log it to the grid or Reject — staying in sync with the',
'web panel and the Matrix review room.',
].join(' '),
},
migrations: { up: async () => {}, down: async () => {} },
})