Skip to content

fix(agents): make header CTAs mobile-friendly - #2310

Merged
2witstudios merged 2 commits into
masterfrom
fix/agents-header-mobile
Aug 3, 2026
Merged

2witstudios merged 2 commits into
masterfrom
fix/agents-header-mobile

Conversation

@2witstudios

@2witstudios 2witstudios commented Aug 2, 2026 •

Copy link
Copy Markdown
Owner

Problem

The /agents header row (New Drive / New Agent / New Session) overflows on mobile screens — three full-label buttons don't fit.

Fix

Wrapped each button's text label in <span className="hidden sm:inline ml-1">. On screens below the sm breakpoint, only the + icon shows. At sm and up, full labels appear as before.

Text nodes stay in the DOM (display: none, not removed) so accessible names are preserved for screen readers and existing tests.

Test status

Tests couldn't run in sandbox due to a pre-existing React.act is not a function error (React 19 / @testing-library/react version mismatch in this environment). The change is CSS-only — no logic, props, or event handlers touched.

Files changed

  • apps/web/src/components/agents/AgentsListHeader.tsx (6 lines)

Summary by CodeRabbit

  • Accessibility

    • Added accessible labels to the Agents header action buttons.
  • UI Improvements

    • Improved button spacing and responsive behavior.
    • Action labels are hidden on small screens and shown on larger screens.

Button text labels now hidden below the sm breakpoint, showing only
the + icon. Full labels appear at sm and up. Prevents the three-button
row (New Drive / New Agent / New Session) from overflowing on narrow
screens.

Text nodes remain in the DOM (display: none via Tailwind hidden) so
accessible names are preserved for tests and screen readers.
@coderabbitai

coderabbitai Bot commented Aug 2, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: d4e3ef7f-a6dd-4476-9342-708b622873d4

📥 Commits

Reviewing files that changed from the base of the PR and between fc57cf2 and 1a429fc.

📒 Files selected for processing (1)
  • apps/web/src/components/agents/AgentsListHeader.tsx

📝 Walkthrough

Walkthrough

The agent header action buttons now have accessible labels, separate icon spacing, and responsive text visibility. Button labels remain visible from the sm breakpoint.

Changes

Agent header actions

Layer / File(s) Summary
Responsive accessible buttons
apps/web/src/components/agents/AgentsListHeader.tsx
The New Drive, New Agent, and New Session buttons now include aria-label values. Their labels are hidden on small screens, and icon spacing is adjusted.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the mobile responsiveness improvements to the agents header CTAs.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/agents-header-mobile

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 ESLint

If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.

ESLint install failed. For unrecoverable errors, disable the tool in CodeRabbit configuration.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 9f15655957

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread apps/web/src/components/agents/AgentsListHeader.tsx
Addresses Codex P1: hidden span text is removed from the accessibility
tree on mobile. Adding aria-label ensures screen readers always have a
button name regardless of breakpoint.
@2witstudios
2witstudios merged commit 1d540f9 into master Aug 3, 2026
3 checks passed
@2witstudios
2witstudios deleted the fix/agents-header-mobile branch August 14, 2026 13:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant