Skip to content

Conversation

@yongkangc
Copy link

@yongkangc yongkangc commented Dec 22, 2025

Problem
When reviewing diffs, users cannot see untracked or gitignored files. This makes it difficult to know what files exist in the repository but aren't being tracked or are intentionally ignored.

Solution
Add a collapsible "Files" panel (similar to the Commits panel) that shows all repository files organized by status:

  • Changed files (from current diff)
  • Untracked files (not yet tracked by git)
  • Gitignored files (matching .gitignore patterns)

Changes

  • Add GET /api/files/{repo_idx} endpoint to list files by status
  • Add GET /api/file-content/{repo_idx} endpoint to view file contents
  • Create FileBrowser.tsx component with collapsible panel
  • Add FileContentModal for viewing untracked/gitignored file contents
  • Filter toggles to show/hide each file category
  • Click changed files to scroll to diff, click others to open modal
  • Group gitignored directories by top-level to avoid listing thousands of files

Impact
Users can now see and view all files in their repository, including those not shown in the diff view. This is especially useful for:

  • Checking what files are being ignored
  • Viewing untracked files before deciding to add them
  • Getting a complete picture of the repository state

Video Demo:

Screen.Recording.2025-12-22.at.10.24.27.AM.mov
image

- Add GET /api/files/{repo_idx} endpoint to list changed, untracked, and gitignored files
- Add GET /api/file-content/{repo_idx} endpoint to view file contents
- Create FileBrowser.tsx component with collapsible panel matching CommitHistory style
- Add FileContentModal for viewing untracked/gitignored file contents
- Filter toggles for Changed/Untracked/Gitignored categories
- Click changed files to scroll to diff, click others to open modal
- Group gitignored directories by top-level to avoid listing thousands of files
@yongkangc
Copy link
Author

cc @cfal let me know what u think here. not sure if there's a better way we can present the file diffs. Doesnt really work great with mobile right now as well.

I think there might still be some feeling missing, so would love ur thoughts!

Store filter checkbox states (Changed, Untracked, Gitignored) in localStorage
keyed by repository label. Default Untracked and Gitignored to unchecked
since most users want to focus on changed files initially.
@yongkangc yongkangc changed the title Add file browser panel for viewing untracked and gitignored files feat: Add file browser panel for viewing untracked and gitignored files Dec 22, 2025
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