Repository navigation
ios: mark workspace read/unread from terminal menu; chat button top-level - #6362
Conversation
…op-level - Add a "Mark as Read"/"Mark as Unread" row to the terminal-icon picker menu (top-right), mirroring the workspace list's swipe action. Flips the current workspace's read state on the Mac; only shown when the Mac advertises read-state actions. - Remove the dedicated New Workspace top-bar button (it stays in the picker menu). The agent-chat toggle remains a top-level button in that freed slot (next to the terminal picker), shown only when the visible tab has a session. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
📝 WalkthroughWalkthrough
ChangesiOS WorkspaceDetailView toolbar and picker menu
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 21 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (21 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Greptile SummaryReworks the workspace detail toolbar on iOS: removes the dedicated New Workspace button from the three trailing toolbar declarations (terminal, chat, browser panes) and adds a capability-gated Mark as Read / Mark as Unread toggle to the terminal-icon picker menu, mirroring the workspace list's swipe action.
Confidence Score: 5/5Safe to merge — localized SwiftUI toolbar and menu changes that call an existing Mac mutation API with capability gating and no new auth or data paths. All three iOS toolbar removals are straightforward and the macOS path is intentionally preserved via No files require special attention. Important Files Changed
Sequence Diagram%%{init: {'theme': 'neutral'}}%%
sequenceDiagram
participant User
participant TerminalPickerMenu
participant WorkspaceDetailView
participant Store
participant MacApp
User->>TerminalPickerMenu: Tap terminal icon
TerminalPickerMenu->>WorkspaceDetailView: Check supportsWorkspaceReadStateActions
WorkspaceDetailView-->>TerminalPickerMenu: Show "Mark as Read/Unread" row (if supported)
User->>TerminalPickerMenu: Tap "Mark as Read" / "Mark as Unread"
TerminalPickerMenu->>WorkspaceDetailView: toggleWorkspaceReadStateFromMenu()
WorkspaceDetailView->>Store: "Task { await setWorkspaceUnread(id:, markUnread:) }"
Store->>MacApp: Send mutation (IPC/XPC)
MacApp-->>Store: Re-sync authoritative workspace list
Store-->>WorkspaceDetailView: workspace.hasUnread updated (Observable)
%%{init: {'theme': 'base', 'themeVariables': {"darkMode": true, "background": "#0d1117", "primaryColor": "#21262d", "primaryTextColor": "#e6edf3", "primaryBorderColor": "#8b949e", "lineColor": "#8b949e", "textColor": "#e6edf3", "edgeLabelBackground": "#161b22", "actorBkg": "#21262d", "actorBorder": "#8b949e", "actorTextColor": "#e6edf3", "actorLineColor": "#8b949e", "signalColor": "#8b949e", "signalTextColor": "#e6edf3", "noteBkgColor": "#373320", "noteBorderColor": "#d4a72c", "noteTextColor": "#f0e6c0", "labelBoxBkgColor": "#21262d", "labelBoxBorderColor": "#8b949e", "labelTextColor": "#e6edf3", "loopTextColor": "#e6edf3", "activationBkgColor": "#30363d", "activationBorderColor": "#8b949e"}}}%%
sequenceDiagram
participant User
participant TerminalPickerMenu
participant WorkspaceDetailView
participant Store
participant MacApp
User->>TerminalPickerMenu: Tap terminal icon
TerminalPickerMenu->>WorkspaceDetailView: Check supportsWorkspaceReadStateActions
WorkspaceDetailView-->>TerminalPickerMenu: Show "Mark as Read/Unread" row (if supported)
User->>TerminalPickerMenu: Tap "Mark as Read" / "Mark as Unread"
TerminalPickerMenu->>WorkspaceDetailView: toggleWorkspaceReadStateFromMenu()
WorkspaceDetailView->>Store: "Task { await setWorkspaceUnread(id:, markUnread:) }"
Store->>MacApp: Send mutation (IPC/XPC)
MacApp-->>Store: Re-sync authoritative workspace list
Store-->>WorkspaceDetailView: workspace.hasUnread updated (Observable)
Reviews (2): Last reviewed commit: "ci: trim toolbar comments + bump Workspa..." | Re-trigger Greptile |
Shorten the (triplicated) chat-toggle toolbar comment and refresh the swift-length budget for WorkspaceDetailView.swift to its new size (757) after adding the mark-read/unread menu row. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…r + ios chat top-level) - v1 debug/test control dispatch cut over to ControlCommandCoordinator (manaflow-ai#6343) - iOS workspace read/unread from terminal menu, chat button promoted (manaflow-ai#6362) - iOS unread-workspace count badge on back button (manaflow-ai#6350) Adapter: stub v2DebugSidebarVisible / v2DebugIsTerminalFocused / v2DebugSimulateTerminalFileDrop call sites with .err(unimplemented). Bodies moved into ControlCommandCoordinator upstream; v2 ctl path not used by cmux_term workflow.
Merge brings in the back-button unread badge (#6350) and mark read/unread + chat-top-level toolbar (#6362). Resolved the swift-length-budget conflict to a single WorkspaceDetailView entry. Also in this branch update: - Add "Rename Workspace" to the terminal-icon picker menu (gated on supportsWorkspaceActions), presenting the shared WorkspaceRenameSheet and forwarding the new name via store.renameWorkspace. Sheet attached across the terminal / chat / browser panes so it works from any mode. - Increase the glass title pill's vertical padding (5 -> 9) so its glass background height matches the back button and other bar-button glass items. Padding-based (not a fixed height) so the multi-line chat header pill grows. - Bump WorkspaceDetailView length budget to 839. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
What
How
terminalPickerMenuContent: new section with a single toggle row that reads "Mark as Read" when the workspace is unread and "Mark as Unread" otherwise (envelope.open/envelope.badge). Action callsstore.setWorkspaceUnread(id:, !hasUnread), which sends the mutation to the Mac and re-syncs the authoritative list. Gated onstore.supportsWorkspaceReadStateActionsso it's hidden on older Macs.newWorkspaceToolbarButton, leaving[chatToggleButton, terminalPickerToolbarButton].Reuses existing localized strings
mobile.workspace.markRead/mobile.workspace.markUnread(en + ja already present); no new user-facing strings.Builds on the unread-count work (#6350): opening a workspace marks it read, and this gives an explicit re-flag-as-unread path.
Verification
dev.cmux.ios.mkunrd) + macOS app on the same tag.Need help on this PR? Tag
/codesmithwith what you need. Autofix is disabled.Note
Low Risk
Localized iOS toolbar and menu wiring reusing existing
setWorkspaceUnreadand capability gating; no auth or data-model changes.Overview
On workspace detail (terminal, chat, and browser chrome), the top bar no longer shows New Workspace; that action stays in the terminal picker menu. The agent chat toggle remains a top-level trailing button next to the picker.
The terminal picker menu gains Mark as Read / Mark as Unread for the current workspace (same behavior as the list swipe), shown only when
supportsWorkspaceReadStateActionsis true. It callssetWorkspaceUnreadon the Mac and re-syncs list state.The Swift file-length budget for
WorkspaceDetailView.swiftis bumped to match the added lines.Reviewed by Cursor Bugbot for commit bd056a1. Bugbot is set up for automated code reviews on this repo. Configure here.
Summary by cubic
Add a Mark as Read/Unread action to the terminal-icon picker on workspace detail so you can change a workspace’s read state without leaving the view. The New Workspace top-bar button is removed; the agent-chat toggle stays top-level next to the terminal picker when an agent session is present.
New Features
setWorkspaceUnread; shown only whensupportsWorkspaceReadStateActionsis true.Refactors
WorkspaceDetailView.swiftlength budget in.github/swift-file-length-budget.tsvto 757.Written for commit bd056a1. Summary will update on new commits.
Summary by CodeRabbit
Release Notes
New Features
UI Improvements