Skip to content

Optimize worktree list layout to maximize available space #925

Closed

Description

@zhanba

The current worktree list layout in packages/vscode-webui/src/components/worktree-list.tsx reserves space for action buttons (New Task, Diff, Terminal, Delete) even when they are hidden. This consumes approximately 70-80px of horizontal space, which could be better used to display the worktree name or PR status, especially in narrow views.

Relevant code:
https://github.com/TabbyML/pochi/blob/main/packages/vscode-webui/src/components/worktree-list.tsx#L237-L245

          <div
            className={cn(
              "ml-auto flex items-center gap-1 transition-opacity duration-200",
              !isHovered && !showDeleteConfirm
                ? "pointer-events-none opacity-0"
                : "opacity-100",
            )}
          >

Proposed Solution:
Change the action buttons container to use absolute positioning so it overlays the content on the right side when hovered, rather than reserving layout space.

  1. Add relative to the parent container (WorktreeSection row).
  2. Change the buttons container to absolute right-1 (and remove ml-auto).
  3. Add bg-background to the buttons container to ensure it properly overlays text when visible.

This will allow the worktree name and PR status to utilize the full width of the container.

🤖 Generated with Pochi

Activity

  1. wsxiaoys commented on Dec 29, 2025

    @wsxiaoys
    Member
    Image

    Maybe something like explore's subpanel

  2. moved this from Todo to No status in Pochi Taskson Dec 29, 2025
  3. moved this from Todo to In Progress in Pochi Taskson Dec 30, 2025
  4. moved this from In Progress to Done in Pochi Taskson Dec 31, 2025
  5. closed this as completedby moving to Done in Pochi Taskson Dec 31, 2025
  6. moved this from Done to Verified in Pochi Taskson Jan 5, 2026
  7. moved this from Verified to Archived in Pochi Taskson Jan 8, 2026
  8. moved this from Verified to Archived in Pochi Taskson Jan 8, 2026
  9. moved this from Archived to No status in Pochi Taskson Jan 8, 2026
  10. moved this to Archived in Pochi Taskson Jan 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions