Skip to content
Source
Sign inSign up
pingdotgg/t3code

[Bug]: Icon-only buttons have no visible tooltip on hover or focus #47759

Openakj(GitHub profile, opens in a new tab) opened this issue 0 comments

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 T3 Code in the web or desktop app.
  2. Open any dialog or side sheet and hover over (or press Tab to focus) the X close button in the top corner.
  3. Open thread search in the sidebar, type a query, and hover over or focus the small X button inside the search field.
  4. Press Ctrl+F / Cmd+F inside a thread to open the find bar and hover over or focus the up arrow, down arrow, and X buttons.
  5. Attach an image in the composer and hover over or focus the X button on the attachment thumbnail.

Expected behavior

Hovering over or focusing an icon-only button should show a visible text tooltip describing what the button does, matching the accessible name given to screen readers.

Actual behavior

Sighted users with low vision cannot tell what many icon-only buttons do before clicking them. A low vision user reported trouble distinguishing small icons and seeing no tooltips to explain controls. Several controls use the same small X icon for very different actions (closing a dialog, closing a sheet, clearing thread search, closing the find bar, or removing an attachment).

These buttons set an aria-label (a hidden text label read by screen readers), so screen readers announce them, but hovering with a mouse or focusing with a keyboard shows no visible text. The sidebar's "Clear thread search" button is also rendered at the smallest icon-micro size (a 12px glyph), which makes the icon itself hard to identify without text.

The app already has a shared tooltip component, SharedTooltipTrigger, that opens immediately on keyboard focus and after 600 ms on hover, but these buttons do not use it. A rough static count across apps/web found about 60 icon-size Button components in about 40 files without a tooltip (unverified rough count: it excludes raw <button> elements and includes a few decorative buttons).

Where it comes from

  • apps/web/src/components/ui/dialog.tsx:146-152 — dialog close Button has aria-label ("Close") and <XIcon />, no tooltip.
  • apps/web/src/components/ui/sheet.tsx:117-123 — sheet close Button has aria-label ("Close") and <XIcon />, no tooltip.
  • apps/web/src/components/chat/ThreadFindBar.tsx:126-151 — "Previous match", "Next match", and "Close find" Buttons have aria-label only, no tooltips.
  • apps/web/src/components/sidebar/SidebarThreadHeader.tsx:84-96 — "Clear thread search" Button (size="icon-micro", 12px <XIcon />) has aria-label only, no tooltip.
  • apps/web/src/components/chat/ComposerAttachmentStrip.tsx:351-358 — remove attachment Button (size="icon-xs", <XIcon />) has aria-label only, no tooltip (while the retry button right beside it at lines 322-342 uses SharedTooltipTrigger).
  • apps/web/src/components/ui/shared-tooltip.tsx:28,339-346,386 — SharedTooltipTrigger opens immediately on :focus-visible (keyboard focus) and after 600 ms on pointer hover.

Suggested direction

  • Wrap the close buttons inside the shared DialogPopup and SheetPopup primitives with SharedTooltipTrigger so every dialog and sheet gets a tooltip automatically.
  • Add SharedTooltipTrigger to the thread find bar, sidebar search clear button, attachment remove button, and other icon-only controls.
  • Add a lint rule that flags icon-size Button components with an aria-label and no tooltip so new icon-only buttons do not regress.

Related: #45220 (one instance: the right panel "+" button has no tooltip).

Impact

Major degradation or frequent failure

Version or commit

0.1.13, main @ ca36afaeb1d

Environment

Web and desktop (shared apps/web UI). Found by reading the source at ca36afaeb1d, not measured in the running app. Mobile was not checked (it does not use these components).

Logs or stack traces

No response

Screenshots, recordings, or supporting files

No response

Workaround

None for sighted users who do not use a screen reader; users have to click buttons to discover what they do or learn each icon's position by memory.

Drafted by Gemini 4 Neon and reviewed by Claude Opus 5.5 in T3 Code.

  1. akj(GitHub profile, opens in a new tab) added labelsbug

  2. akj(GitHub profile, opens in a new tab) added labelsneeds-triage

Sign in to join this conversation.