fix(web): remove inserted citations on cancel - #10518
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Team Run ID: 📒 Files selected for processing (2)
Included review availability: Your plan provides up to 10 included reviews per hour; 9 remain after this review. 📝 WalkthroughWalkthroughCitation comment targets now track whether cancellation should remove inserted citations. The citation chip receives a shared target and invokes removal when required, while preserving popover closure as the default behavior. ChangesCitation cancellation
Estimated code review effort: 2 (Simple) | ~10 minutes Merge Risk: ⚪ Minimal · up to Canceling a newly inserted citation now removes it and returns focus to the composer, while canceling edits to existing citations continues to close normally. No concrete merge-blocking risk remains. Suggested reviewers: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
ApprovabilityVerdict: Approved at Macroscope's review found this PR approvable — This is a focused web bug fix that removes only citations newly inserted by the cite prompt when their comment editor is cancelled, while preserving normal cancellation for existing citations. The implementation is small, localized, and reuses the composer’s existing removal behavior without changing defaults, schemas, or sensitive infrastructure. You can add or adjust custom eligibility rules. Learn more. |
## What's Changed * feat(web): group onboarding project import by repository by @t3dotgg in pingdotgg/t3code#10493 * fix(web): remove inserted citations on cancel by @extoci in pingdotgg/t3code#10518 * fix(mobile): match Working status color to desktop by @baptisteArno in pingdotgg/t3code#10515 ## New Contributors * @baptisteArno made their first contribution in pingdotgg/t3code#10515 **Full Changelog**: pingdotgg/t3code@v0.0.40-nightly.20260907.1346...v0.0.40-nightly.20260907.1359 Upstream release: https://github.com/pingdotgg/t3code/releases/tag/v0.0.40-nightly.20260907.1359
* origin/main: (675 commits) fix(web): tolerate servers that predate git identity in project import (pingdotgg#10547) chore(mobile): bump app version to 1.1.0 fix(mobile): wait for native thread scroll before reveal (pingdotgg#10486) fix(mobile): match Working status color to desktop fix(web): remove inserted citations on cancel (pingdotgg#10518) feat(web): group onboarding project import by repository (pingdotgg#10493) fix(mobile): preserve chat rows when toggling commands (pingdotgg#10492) fix(mobile): restore assistant message bottom padding (pingdotgg#10491) fix(mobile): animate thread lifecycle transitions consistently (pingdotgg#10487) fix(mobile): release initial scroll target after dragging (pingdotgg#10483) fix(mobile): smooth composer status pill resizing (pingdotgg#10484) fix(mobile): prevent chat from disappearing when scrolling (pingdotgg#10479) fix(web): resize the floating preview from any edge (pingdotgg#10467) fix(web): keep composer toolbar controls anchored during transitions (pingdotgg#10478) fix(mobile): improve font-size slider performance and prevent maximum update depth errors (pingdotgg#7138) feat(mobile): start a new thread on an existing branch (pingdotgg#10359) fix(ios): scroll short source files from blank space (pingdotgg#10178) fix(mobile): hide changed-files navigator and restore refresh in raw diff fallback (pingdotgg#9828) fix(projects): prevent invalid script IDs from crashing threads (pingdotgg#10019) fix(devcontainer): make repository setup work (pingdotgg#7875) ... # Conflicts: # apps/server/src/provider/builtInDrivers.ts # docs/README.md # docs/user/install.md # packages/contracts/src/settings.test.ts # packages/contracts/src/settings.ts
Canceling the cite prompt currently leaves the citation chip that the prompt inserted in the composer.
Mark citation targets created by the cite prompt for removal on cancel. Existing citation edits still close normally, while canceling a fresh citation removes it and returns focus to the composer.
Validation: 29 focused composer tests pass, web typecheck passes, targeted lint and formatting pass. Browser verification has not been run.
Model: GPT-5.6 Sol. Harness: Codex.
Note
Remove inserted citations when comment is cancelled in
ComposerCitationDecoratorAdds an optional
removeOnCancelflag to theComposerCitationCommentTargettype so controlled citation comment requests can signal that their matched citation node should be deleted on cancel. ComposerCitationNode.tsx now passes the citation removal handler as the comment editor's cancel callback when that flag is set. AssistantCitationChip.tsx adds an optionalonCancelcallback to the comment editor; callers without the callback keep the existing close-only behavior.Macroscope summarized 843cebe.
Summary by CodeRabbit