Skip to content

Add collapsible file diffs + @pierre/diffs version update.#2502

Merged
juliusmarminge merged 5 commits intopingdotgg:mainfrom
shivamhwp:diffs-update
May 5, 2026
Merged

Add collapsible file diffs + @pierre/diffs version update.#2502
juliusmarminge merged 5 commits intopingdotgg:mainfrom
shivamhwp:diffs-update

Conversation

@shivamhwp
Copy link
Copy Markdown
Collaborator

@shivamhwp shivamhwp commented May 4, 2026

  • Upgrade @pierre/diffs to 1.1.20
  • Add per-file diff collapse controls in the panel

What Changed

Updated @pierre/diffs to 1.1.20 in both apps/web and apps/server.

Added collapsible file diffs in the diff panel. Each file diff can now be collapsed/expanded from the existing left status-icon position:

  • expanded: original file status icon remains visible
  • hover/focus on the icon: caret-down is shown
  • collapsed: caret-right is shown

Why

The package upgrade brings the app onto the latest @pierre/diffs version and uses its built-in collapsed option for file diffs.

The collapse control keeps the existing header layout intact by reusing the current status-icon position instead of adding another control to the left. This keeps the UI compact while making diff state clear.

UI Changes

Screen.Recording.2026-05-04.at.10.34.50.PM.mov

Checklist

  • This PR is small and focused
  • I explained what changed and why
  • I included before/after screenshots for any UI changes
  • I included a video for animation/interaction changes

Note

Medium Risk
Moderate UI/UX change in the diff viewer plus a dependency upgrade; risk is mainly regressions in diff rendering/click handling and any behavior changes from @pierre/diffs v1.1.20.

Overview
Upgrades @pierre/diffs across apps/web and apps/server by switching to the workspace catalog: pin (now 1.1.20), updating the lockfile accordingly.

Updates DiffPanel to support collapsing individual file diffs via a chevron button in each file header (persisted per rendered file key and pruned when the visible file list changes), and widens the inline diff sidebar max width substantially (from 36rem to 256rem).

Reviewed by Cursor Bugbot for commit 15a3c5e. Bugbot is set up for automated code reviews on this repo. Configure here.

Note

Add collapsible file diffs and increase inline diff sidebar max width

  • Adds per-file collapse/expand state to DiffPanel, rendered as a chevron button in each file header; clicking the chevron stops event propagation so it does not trigger 'open in editor'.
  • Adds getDiffCollapseIconClassName to color the chevron based on diff type (new, deleted, modified).
  • Increases DIFF_INLINE_SIDEBAR_MAX_WIDTH from 36 * 16 to 256 * 16 px in _chat.$environmentId.$threadId.tsx.
  • Updates @pierre/diffs to 1.1.20 via catalog reference across server and web packages.

Macroscope summarized 15a3c5e.

- Upgrade @pierre/diffs to 1.1.20
- Add per-file diff collapse controls in the panel
@vercel
Copy link
Copy Markdown

vercel Bot commented May 4, 2026

@shivamhwp is attempting to deploy a commit to the Ping Labs Team on Vercel.

A member of the Team first needs to authorize it.

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 4, 2026

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 9895ec6d-eb0e-4abc-bc4e-203a89200a61

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Tip

💬 Introducing Slack Agent: The best way for teams to turn conversations into code.

Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.

  • Generate code and open pull requests
  • Plan features and break down work
  • Investigate incidents and troubleshoot customer tickets together
  • Automate recurring tasks and respond to alerts with triggers
  • Summarize progress and report instantly

Built for teams:

  • Shared memory across your entire org—no repeating context
  • Per-thread sandboxes to safely plan and execute work
  • Governance built-in—scoped access, auditability, and budget controls

One agent for your entire SDLC. Right inside Slack.

👉 Get started


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions github-actions Bot added size:L 100-499 changed lines (additions + deletions). vouch:trusted PR author is trusted by repo permissions or the VOUCHED list. labels May 4, 2026
@macroscopeapp
Copy link
Copy Markdown
Contributor

macroscopeapp Bot commented May 4, 2026

Approvability

Verdict: Needs human review

This PR introduces new user-facing behavior (collapsible file diffs) along with a dependency upgrade and a significant max-width constant change. New UI features that affect user interaction patterns warrant human review to ensure the experience meets expectations.

You can customize Macroscope's approvability policy. Learn more.

- Remove hover-specific diff icon state and styling
- Keep collapse controls always visible with simpler header buttons
- Lift the inline diff sidebar width cap
@github-actions github-actions Bot added size:M 30-99 changed lines (additions + deletions). and removed size:L 100-499 changed lines (additions + deletions). labels May 4, 2026
- Normalize @pierre/diffs to the shared catalog entry
- Refresh lockfile and root package metadata
@juliusmarminge juliusmarminge merged commit f4c9418 into pingdotgg:main May 5, 2026
11 of 12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:M 30-99 changed lines (additions + deletions). vouch:trusted PR author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants