Skip to content

fix(desktop): keyboard focus visible again on sidebar, tabs, composer, right-sidebar (#93462) - #93686

Merged
teknium1 merged 2 commits into
mainfrom
fix/93462-focus-visible-affordance
Aug 24, 2026
Merged

teknium1 merged 2 commits into
mainfrom
fix/93462-focus-visible-affordance

Conversation

@teknium1

Copy link
Copy Markdown
Collaborator

Summary

Keyboard focus is visible again across the desktop's sidebar nav, tabs, composer micro-actions, right-sidebar controls, and terminal rail. The intentional global no-ring reset zeroes --tw-ring-shadow with !important, and these components relied solely on focus-visible:ring-* — so tabbing produced no visible focus at all. Fixes #93462.

Changes

  • Background/text focus-visible affordances mirroring each component's hover state at: components/ui/sidebar.tsx (5 sites), tabs.tsx, text-tab.tsx, composer/micro-actions.tsx, right-sidebar/index.tsx (HEADER_ACTION_CLASS), right-sidebar/terminal/rail.tsx
  • Repo-wide sweep found and fixed 4 more ring-only sites (incl. cron-jobs sidebar rows); everything else already pairs ring with a border/bg companion or belongs to open fix(desktop): show a visible focus state on row-list keyboard focus #93460 (not overlapped)
  • Global no-ring reset kept intact

Validation

Before After
Tab through sidebar/tabs/composer invisible focus hover-mirrored highlight
Tests — 30 targeted + full chat/sidebar suite 202 passed

Reported by @fred0m (with the correct root-cause analysis).

Infographic

Keyboard focus is visible again

…al no-ring reset hides it

The unlayered *:focus-visible reset in styles.css intentionally zeroes
--tw-ring-shadow ('No focus rings, anywhere'), so any control that relied
solely on focus-visible:ring-* had no visible keyboard focus state at all.
Mirror each control's hover treatment as a focus-visible background/text
affordance instead, keeping the global reset intact:

- ui/sidebar.tsx: group label, group action, menu button, menu action,
  menu sub-button get focus-visible:bg-sidebar-accent + accent foreground
- ui/tabs.tsx: TabsTrigger gets focus-visible:bg-background + text-foreground
- ui/text-tab.tsx: focus-visible:text-foreground (matches its hover)
- chat/composer/micro-actions.tsx: pill gets focus-visible chrome-action-hover
- right-sidebar/index.tsx HEADER_ACTION_CLASS: focus-visible sidebar-accent
- right-sidebar/terminal/rail.tsx RAIL_ACTION: focus-visible chrome-action-hover
- chat/sidebar/cron-jobs-section.tsx (row body + run rows): focus-visible
  chrome-action-hover
- chat/sidebar/session-row.tsx <time>: focus-visible:text-foreground

Sweep verified: remaining focus-visible:ring-* usages under apps/desktop/src
already pair with a border/bg/text companion (button/checkbox/switch/input,
starmap share-controls) or are covered by PR #93460's row-hover work
(cron/index.tsx run rows).

Fixes #93462. Reported by @fred0m.
@alt-glitch alt-glitch added type/bug Something isn't working P2 Medium — degraded but workaround exists comp/desktop Electron desktop app (apps/desktop/*) labels Aug 24, 2026
@github-actions

github-actions Bot commented Aug 24, 2026 •

Copy link
Copy Markdown

૮ >ﻌ< ა ci review

ran on 0afc357 — ci: retrigger — no workflow run ever dispatched

⚠️ Warnings

OSV vulnerability scan · View job

7 known vulnerabilities found in pinned dependencies.

How to fix:

Review the findings in the Security tab. Update the affected dependencies if a patched version is available.


debug info

CI timings

CI timings · View report · View job

Wall time 3m34s vs 3m59s (-10.5%). 2 job(s) slower, 2 faster, 2 unchanged.

  • JS & TS checks / JS & TS checks: +26.0s
  • OSV scan / Scan lockfiles / osv-scan: -6.0s
  • Detect affected areas: +2.0s
  • All required checks pass: -1.0s

@teknium1
teknium1 merged commit 1bee67b into main Aug 24, 2026
29 checks passed
@teknium1
teknium1 deleted the fix/93462-focus-visible-affordance branch August 24, 2026 10:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/desktop Electron desktop app (apps/desktop/*) P2 Medium — degraded but workaround exists type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: focus-visible:ring is dead across several desktop components (sidebar nav, tabs, composer, right-sidebar)

2 participants