Repository navigation
feat(web): send a citation to another thread from its comment panel - #442
Merged
Merged
Conversation
The citation comment panel gets a destination picker: this thread, a new thread, or any other thread in the environment. Its split button then acts on that thread: Send starts or queues a turn there with the thread's own model and modes, Save adds the quote to its composer, and Save as draft stores a message draft there. A new thread starts in this project with the quote as its first message, or opens with it in the composer. Quotes shown outside their source thread name it in their preview. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Citing assistant text could only put the quote in the current thread's composer. To use it elsewhere you had to copy text by hand, which lost the link back to the source.
What changed
The comment panel that opens after Cite now has a destination picker on the left of its footer. It always starts on This thread, so the existing flow is unchanged. The picker searches threads in the environment, running threads first, with This thread and New thread pinned at the top. Once you pick another destination, the panel's split button acts on it:
You stay on the current thread. A toast confirms where the quote went and has Open. The quote leaves this composer only once it has arrived, and a failure leaves it where it was. The quote travels as the same serialized citation link the composer already sends, so no contract or server changes were needed. Hovering a quote shown outside its source thread now says "From ".
Surfaces
t3_thread_send.docs/user/composer.mdanddocs/fork-differences.md.Not in this PR
expandAssistantCitationsForProviderisn't called anywhere outside the web composer's prompt-length check, so agents receive the raw citation markup.Testing
citationDestination.test.ts: thread ranking and filtering, and appending to a prompt.AssistantCitationChip.browser.test.tsx: picks a running thread in the panel, checks the button reads Add to queue, and that sending submits that destination.🤖 Generated with Claude Code