Skip to content

refactor(web): reuse upstream presentation in Linear panel, file actions and minimap tests - #301

Merged
pandec merged 4 commits into
devfrom
chore/audit2-web-chat-trims
Nov 25, 2026
Merged

pandec merged 4 commits into
devfrom
chore/audit2-web-chat-trims

Conversation

@pandec

@pandec pandec commented Nov 25, 2026

Copy link
Copy Markdown
Owner

The fork kept its own copies of presentation that upstream now provides: Linear label pills and the branch copy button, English-only file-path copy labels, and a test-only minimap wrapper. This shrinks the fork diff on the touched files from 2586 to 2555 changed lines. Behavior stays the same.

  • T6 (remove): I dropped deriveTimelineMinimapItems and the unused TimelineMinimapKind. The minimap tests now assert computeTimelineMinimapState(...).userItems / .assistantItems directly. The final-response and pin cases remain.
  • T21 (simplify): File-path copy labels and failure toasts now use upstream's translated message keys, and the English-only filePathCopyLabel is gone. The clipboard path was already upstream's writeTextToClipboard. Sharing upstream's inline MarkdownFileLink copy handler would require editing upstream, so I left it.
  • T11 (simplify, partial): The Linear panel now renders labels with upstream PullRequestLabelChip and the branch name with PullRequestCopyableCode. Both use upstream's branch-name clipboard strings, and a toast reports a failed copy. The fork LinearLabelPill and CopyButton are gone. IssueDetailPanel, IssueLinkPreview and IssueCommentComposer were not reused, because each loads its own data through issueEnvironment atoms. The composer also keeps its own draft state, so reusing it would lose per-tab drafts, and the preview card body is private. Fork routing, the Linear connection, the rich fields and the per-tab drafts are unchanged.
  • T12 (skipped): ContextWindowMeter uses the fork's ProviderUsageWindow type, which tracks used percent and status. Upstream renders ServerProviderUsageWindow, which tracks remaining percent and shows pace ticks. Upstream's row components are private, and its context-window row uses different thresholds (80/90). The meter already reuses upstream's token, compaction and USD formatters, so any further reuse would grow the diff or change behavior.

Checks: vp check, vp run typecheck, vp run i18n:check, and focused web tests (fileContextMenu, RightPanelTabs, MessagesTimeline minimap/logic, linear).

Implemented by Claude Opus 5.5 in Claude Code (T3 Code). Reviewed by Astra (Codex) and Opus code-reviewer.

@pandec
pandec merged commit 19c2044 into dev Nov 25, 2026
3 checks passed
@pandec
pandec deleted the chore/audit2-web-chat-trims branch November 25, 2026 08:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant