Agents Window: Files tab should show the file tree when no file is open
- Dominant language
- TypeScript
- Stars
- 193k
- Forks
- 42.4k
- PR merge metrics
- PR metrics pending
Description
In the Agents Window, the **Files** tab should always show the workspace file tree when there is no file currently open in that tab.
## Expected behavior
- Opening or activating the Files tab with no selected/open file shows the file tree immediately.
- The tab should not present an empty editor/content area while waiting for a file to be opened.
- This behavior should apply to new-session and existing-session flows where a workspace is available.
- If a previously open file is closed and no other file editor remains, the Files tab should fall back to the file tree.
- Session switching and reload/restoration should preserve this invariant.
## Why
The Files tab represents the entry point for browsing the session workspace. When no file is open, the file tree is the useful default content and avoids an ambiguous empty state.
Related but broader scenarios:
- #327343 tracks the Files tree being lost after selecting and closing a file.
- #325213 tracks the side pane becoming unavailable on the new-chat page after closing a file.
- #324564 covered an older empty Files-view regression and is already completed.
Contributor guide
Assessment
This issue has not been assessed yet.