🤖 feat: allow collapsing attached reviews in the chat decoration#3486
Open
ammar-agent wants to merge 1 commit into
Open
🤖 feat: allow collapsing attached reviews in the chat decoration#3486ammar-agent wants to merge 1 commit into
ammar-agent wants to merge 1 commit into
Conversation
Wrap the AttachedReviewsPanel in the ChatInputDecoration primitive so the reviews attached to a pending message can be collapsed/expanded like the other composer decorations. The collapsed/expanded intent persists per-workspace and defaults to expanded to preserve the prior always-visible behavior.
Collaborator
Author
|
@codex review |
|
Codex Review: Didn't find any major issues. 🎉 ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
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
Make the "Attached Reviews" panel in the chat composer collapsible by rendering it through the shared
ChatInputDecorationprimitive, so a pending message with many attached reviews can be tucked away without detaching them.Background
Reviews attached to the pending message were always rendered fully expanded above the textarea. When several reviews are attached, the panel could consume a large portion of the composer area and push the input around. Every other composer-adjacent decoration (pending reviews banner, pinned TODO list, queued message, background processes) already uses the collapsible
ChatInputDecorationchrome; the attached-reviews panel was the odd one out.Implementation
AttachedReviewsPanelnow wraps its contents inChatInputDecoration:usePersistedStateunder a newgetAttachedReviewsExpandedKey(workspaceId)storage key, defaulting to expanded to preserve the prior always-visible behavior.ChatInputpassesworkspaceIdto the panel (only rendered in theworkspacevariant).Validation
make typecheck,make static-check, and targetedeslinton the touched files all pass.Risks
Low. Scope is limited to the composer's attached-reviews preview; detach/clear/edit handlers are unchanged, and the default expanded state preserves existing behavior. Worst case is a per-workspace UI preference being mis-persisted, which self-heals on toggle.
Generated with
mux• Model:anthropic:claude-opus-4-8• Thinking:xhigh• Cost:n/a