feat(web): replace flat file list with file-tree in merge review diff#443
Open
feat(web): replace flat file list with file-tree in merge review diff#443
Conversation
Add the Magic UI file-tree component adapted for the project's radix-ui setup. Includes Tree, Folder, File, CollapseButton sub-components with accordion-based expand/collapse, selection tracking, and sorting. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Replace the flat list in the merge review DiffView component with a hierarchical file tree using the Magic UI file-tree component. Files are grouped by directory with collapsible folders, single-child folder paths are collapsed, and clicking a file shows its diff hunks below the tree. Status icons (added/modified/deleted/renamed) and line counts are preserved on each file node. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Fix multiline string formatting for oneLiner field that was breaking the yaml parser due to unindented continuation line. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
… tree Folders now start collapsed (only top-level expanded) so the tree structure is visually obvious. Each folder displays a file count badge. Removed isSelectable=false from folders so they can be clicked to expand/collapse. Previously all folders were expanded by default which made the tree look identical to a flat file list. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
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.
Summary
packages/core/src/)Fix for Rejection Feedback
The initial implementation expanded ALL folders by default, making the tree visually indistinguishable from a flat list. This fix:
src (4),components (1))isSelectable={false}which was preventing folder expand/collapsetext-muted-foregroundcolor to distinguish from filesChanges
src/presentation/web/components/ui/file-tree.tsx— Magic UI FileTree component with folder/file icons and tree indicatorssrc/presentation/web/components/common/merge-review/diff-view.tsx— Replaced flat file list withbuildFileTree()that groups files into a hierarchical tree with collapsed folders showing file countsFileTreeandDiffViewcomponents covering default, deep nesting, and root-level file scenariosbuildFileTree,DiffViewrendering, file expansion, folder expansion, renamed files, and tree structureEvidence
Test plan
🤖 Generated with Claude Code