fix(web-ui): lock chat input mode controls for Claw sessions#1323
Merged
Conversation
Centralize chat input mode policy so fixed collaboration sessions are handled consistently across the mode capsule, boost menu, slash commands, and keyboard mode cycling. - Treat Claw, Cowork, assistant workspace, and ACP sessions as fixed-mode contexts - Keep Claw sessions pinned even when assistant workspace resolution is temporarily stale - Filter fixed collaboration modes out of selectable chat input boosts - Add focused coverage for fixed-mode policy and Claw synchronization
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Centralize chat input mode policy so fixed-mode sessions consistently hide mode controls.
Fixes #
Type and Areas
Type:
bug fix
Areas:
web UI, flow chat
Motivation / Impact
Assistant (
Claw) sessions could show the mode capsule and allow mode switching when opened after a normal session, especially while assistant workspace resolution lagged behind the active session state.This PR treats
Claw,Cowork, assistant workspace, and ACP sessions as fixed-mode contexts for ChatInput. The mode capsule, plus-menu mode options, slash-command modes, and keyboard mode cycling now follow the same policy.Verification
pnpm --dir src/web-ui run test:run src/flow_chat/utils/chatInputMode.test.tspnpm run type-check:webReviewer Notes
The main behavior is now owned by
src/web-ui/src/flow_chat/utils/chatInputMode.tsviaresolveChatInputModePolicyandresolveSwitchableChatInputModes, keeping ChatInput from scatteringClaw/Coworkspecial cases.Checklist