Skip to content

[Bug]: Right-panel and terminal tab activation buttons only cover the label text instead of the full tab pill #47014

Done

Description

@vojtechpavelka

Before submitting

  • I searched existing issues and did not find a duplicate.
  • I included enough detail to reproduce or investigate the problem.

Area

apps/web

Steps to reproduce

  1. Open a thread with two or more tabs in the right panel (for example, Browser and Diff, or a Device tab).
  2. Hover over an inactive tab and click or double-click in the tab pill's padding (top/bottom 4px edge, right 8px padding, or left 6px padding outside the close button) rather than directly on the label text.
  3. Also open two terminals in the terminal drawer so the terminal sidebar list appears, hover over the inactive terminal tab, and click in its padding (top/bottom/right/left outside the label text).

Expected behavior

Clicking anywhere on the tab pill outside its close button (and mute button, if shown) should target the tab's activation <button> and switch to that tab. Hovering the tab body should also trigger the tab's tooltip, and double-clicking anywhere on a device tab body should start rename.

Actual behavior

In apps/web/src/components/RightPanelTabs.tsx (RightPanelTab), the outer tab pill <div data-active-tab> is 24px tall (h-6) with pl-1.5 (6px), pr-2 (8px), and gap-0.5 (2px), while the activation <button> (className="cursor-pointer flex min-w-0 items-center") is shrink-wrapped tightly around the 16px-tall label text with no height or padding:

  • In builds prior to PR feat(web): select and manage multiple side-panel tabs #43946 (ddcc48f21e), the outer <div> had no onClick handler at all, so clicking anywhere outside the label text did nothing.
  • On current main (181bd02092), PR feat(web): select and manage multiple side-panel tabs #43946 added an if (event.target === event.currentTarget) fallback on the outer <div>, so bare div clicks activate the tab, but the activation <button> itself is still shrink-wrapped to the text. As a result, hovering the padding does not trigger SharedTooltipTrigger, double-clicking the padding on a device tab does not start rename, and clicking padding does not focus the activation button.
  • In apps/web/src/components/ThreadTerminalDrawer.tsx (TerminalSidebarGroup), terminal tabs use the exact same group/tab + PanelTabCloseButton + shrink-wrapped <button> markup and still have no outer onClick handler on main, so clicking the padding around a terminal tab label does nothing.

Related issues / PRs

Impact

Minor bug or occasional failure

Version or commit

main @ 181bd02092

Workaround

Click directly on the tab label text instead of the surrounding tab padding.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions