feat(mobile): v1.8 tab switcher + branch indicator + git_status tool
Mobile header is now two rows. Row 1: hamburger | project · branch indicator (live via GET /api/projects/:id/git, 30s poll) | ModelPicker | FolderTree. Row 2: pane-switcher pill (hand-rolled BottomSheet) + NewPaneMenu. Chat-within-pane navigation hidden on mobile; users switch panes via the sheet. Cross-tab status sync via chat_status frames published from inference.ts at working/idle/error transitions; StatusDot component renders amber-pulse/green/red/gray on each pane row and on desktop ChatTabBar tabs. Level 1 git awareness exposes a read-only git_status tool to the model, backed by services/git_meta.ts (execFile + 2s timeout + 30s cache). Workspace.tsx now receives panes/chats hooks as props (hoisted into Session.tsx) so the header pill shares state with the pane grid. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -115,6 +115,16 @@ export interface ProjectUpdatedEvent {
|
||||
name: string;
|
||||
}
|
||||
|
||||
// v1.8 mobile-tabs: broadcast on user channel from inference.ts so any device
|
||||
// subscribed sees a chat working/idle/error. Frontend stores per-chat; panes
|
||||
// derive their dot from pane.activeChatId.
|
||||
export interface ChatStatusEvent {
|
||||
type: 'chat_status';
|
||||
chat_id: string;
|
||||
status: 'working' | 'idle' | 'error';
|
||||
at: string;
|
||||
}
|
||||
|
||||
export type SessionEvent =
|
||||
| SessionRenamedEvent
|
||||
| ProjectCreatedEvent
|
||||
@@ -134,7 +144,8 @@ export type SessionEvent =
|
||||
| ChatDeletedEvent
|
||||
| ProjectArchivedEvent
|
||||
| ProjectUnarchivedEvent
|
||||
| ProjectUpdatedEvent;
|
||||
| ProjectUpdatedEvent
|
||||
| ChatStatusEvent;
|
||||
type Listener = (event: SessionEvent) => void;
|
||||
|
||||
const listeners = new Set<Listener>();
|
||||
|
||||
Reference in New Issue
Block a user