Skip to content

[diffs] Dynamic FileDiff Hydration#861

Open
amadeus wants to merge 20 commits into
beta-1.3from
amadeus/dynamic-loader
Open

[diffs] Dynamic FileDiff Hydration#861
amadeus wants to merge 20 commits into
beta-1.3from
amadeus/dynamic-loader

Conversation

@amadeus

@amadeus amadeus commented Jun 20, 2026

Copy link
Copy Markdown
Member

At a high level this PR gives a dev the ability to render a FileDiffMetadata that's partial (parsed from a patch file), and then hydrate the diff when trying to expand lines by providing an API for devs to load the full file contents on expansion.

Additionally there were some extra changes that needed to happen to properly implement this:

  • Resolved an older todo for parsing diffs from two versions of a file that allows you to pass null for new or old files to more easily parse NEW or DELETED files
    • This had a bunch of smaller downstream effects
  • CodeView was just fundamentally broken when it came to hunk expansion because it didn't properly apply the changes for computing anchors and would thusly force bad scroll changes.

@vercel

vercel Bot commented Jun 20, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
pierre-docs-diffs Ready Ready Preview Jun 22, 2026 6:48pm
pierre-docs-diffshub Ready Ready Preview Jun 22, 2026 6:48pm
pierre-docs-trees Ready Ready Preview Jun 22, 2026 6:48pm
pierrejs-diff-demo Ready Ready Preview Jun 22, 2026 6:48pm

Request Review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 2454eab4c4

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

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".

Comment thread packages/diffs/src/components/FileDiff.ts
@amadeus

amadeus commented Jun 20, 2026

Copy link
Copy Markdown
Member Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. 👍

Reviewed commit: 2483d990bc

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

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".

@amadeus

amadeus commented Jun 20, 2026

Copy link
Copy Markdown
Member Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: df085c23b1

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

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".

Comment thread packages/diffs/src/components/VirtualizedFileDiff.ts Outdated
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