Agentic UI: Add a file-change Review tab - #4580
Draft
shaunandrews wants to merge 1 commit into
Draft
Conversation
6 tasks
shaunandrews
force-pushed
the
add-chat-diff-tracker
branch
from
August 18, 2026 16:07
44dc8cf to
36247a2
Compare
7 tasks
shaunandrews
changed the base branch from
add-chat-change-summary
to
add-chat-change-inventory
August 18, 2026 16:09
shaunandrews
force-pushed
the
add-chat-diff-tracker
branch
from
August 18, 2026 16:31
36247a2 to
ae57bac
Compare
shaunandrews
force-pushed
the
add-chat-diff-tracker
branch
from
August 18, 2026 16:32
ae57bac to
4e7334f
Compare
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.
Related issues
How AI was used in this PR
This feature was designed and implemented collaboratively with Codex. AI helped explore several review surfaces, implement the transcript-derived diff view, add tests, and exercise the production build. The interaction and visual design were iterated manually in the running agentic UI.
Executive summary
This is the third PR in a three-PR stack. #4590 adds the display-only change summary, and #4594 adds the per-file inventory. This follow-up adds an optional Review destination to the existing Preview surface, giving larger diffs enough space without replacing the conversation, composer, or live site preview state.
The inventory gains a Review changes action that opens the Preview panel and selects Review. Review presents each file as a collapsible section in a single scrolling column, with bounded previews and lightweight previous/next navigation.
Proposed Changes
Review guide
1. Stacked boundary
Review #4590 and #4594 first. They independently own change derivation, localized totals, composer integration, and the interactive file inventory. This PR should contain only the Review destination and the transition into it.
2. Relationship to Preview
Please focus on whether Review feels like a natural peer to Site, WP Admin, and Database. Selecting Review hides—but does not unmount—the preview webview. Selecting any site destination returns immediately to the warm preview.
3. Diff scanability
Files appear in transcript order. The first is expanded; other sections can be opened independently. Initial previews show 40 lines. Expanded diffs render at most 5,000 lines, retaining both the beginning and end when a diff exceeds the cap.
4. Change semantics
The view reconstructs successful
EditandWriteactivity already stored in the session transcript. Repeated edits to one path are shown consecutively and their counts are aggregated. This is a record of agent activity in the chat, not a reconciliation against Git's current working tree.Screenshots
Native 2560×1440 PNG captures at 100% page scale and 2× device scale, captured from the rebuilt third layer of the stack.
Known tradeoffs and follow-ups
EditandWritetool activity is represented. File mutation through shell commands or WordPress-specific tools remains outside this proof of concept.Safety checklist
Testing Instructions
Automated verification completed locally:
npx eslint --fixon every modified TypeScript/TSX filenpm test -- apps/ui/src/ui-classic/components/session-view/changes-tracker.test.tsx apps/ui/src/ui-classic/components/session-view/index.test.tsx apps/ui/src/hooks/use-session-ui.test.tsx apps/ui/src/components/site-preview/index.test.tsx apps/ui/src/components/site-preview/address-bar.test.tsx— 5 files and 107 tests passednpm run typechecknpm run cli:build:uigit diff --checkPre-merge Checklist