🎨 Palette: Add accessibility to AgentCard buttons#103
Conversation
💡 What: Added aria-labels and focus styles to icon buttons. 🎯 Why: Improve accessibility for screen readers and keyboard users. ♿ Accessibility: Added aria-labels and focus rings. Co-authored-by: bobdivx <6737167+bobdivx@users.noreply.github.com>
|
👋 Jules, reporting for duty! I'm here to lend a hand with this pull request. When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job! For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
Code Review
This pull request enhances the accessibility of icon-only buttons in AgentCard.tsx by adding aria-label attributes, hiding decorative SVGs from screen readers with aria-hidden="true", and implementing keyboard focus styles. These changes are also documented in .Jules/palette.md. The feedback recommends adding focus-visible:ring-offset-2 to the buttons to improve focus ring visibility and contrast, particularly against dark backgrounds.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
| onClick={() => onSwarmCommand?.(agent.id, cmd)} | ||
| disabled={commandBusy} | ||
| class={`rounded-xl border p-2 transition-all disabled:opacity-50 ${cmd === 'start_work' ? 'bg-gray-900 border-gray-900 text-white hover:bg-black' : 'bg-white border-gray-200 text-gray-400 hover:text-rose-500 hover:border-rose-200'}`} | ||
| class={`rounded-xl border p-2 transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[#175B37] disabled:opacity-50 ${cmd === 'start_work' ? 'bg-gray-900 border-gray-900 text-white hover:bg-black' : 'bg-white border-gray-200 text-gray-400 hover:text-rose-500 hover:border-rose-200'}`} |
There was a problem hiding this comment.
The focus ring color focus-visible:ring-[#175B37] (dark green) has very low contrast against the dark gray background (bg-gray-900) of the 'Lancer une mission' button when focused. To ensure the focus indicator is clearly visible for keyboard users and complies with WCAG accessibility guidelines, consider adding focus-visible:ring-offset-2 to create a clear separation between the button and the focus ring.
| class={`rounded-xl border p-2 transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[#175B37] disabled:opacity-50 ${cmd === 'start_work' ? 'bg-gray-900 border-gray-900 text-white hover:bg-black' : 'bg-white border-gray-200 text-gray-400 hover:text-rose-500 hover:border-rose-200'}`} | |
| class={`rounded-xl border p-2 transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[#175B37] focus-visible:ring-offset-2 disabled:opacity-50 ${cmd === 'start_work' ? 'bg-gray-900 border-gray-900 text-white hover:bg-black' : 'bg-white border-gray-200 text-gray-400 hover:text-rose-500 hover:border-rose-200'}`} |
| setConfigOpen(true); | ||
| }} | ||
| class="rounded-xl border border-gray-200 bg-white p-2 text-gray-400 transition-all hover:border-[#175B37]/30 hover:text-[#175B37]" | ||
| class="rounded-xl border border-gray-200 bg-white p-2 text-gray-400 transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[#175B37] hover:border-[#175B37]/30 hover:text-[#175B37]" |
There was a problem hiding this comment.
For consistency and to ensure excellent focus visibility across all interactive elements, consider adding focus-visible:ring-offset-2 to the configuration button as well.
| class="rounded-xl border border-gray-200 bg-white p-2 text-gray-400 transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[#175B37] hover:border-[#175B37]/30 hover:text-[#175B37]" | |
| class="rounded-xl border border-gray-200 bg-white p-2 text-gray-400 transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[#175B37] focus-visible:ring-offset-2 hover:border-[#175B37]/30 hover:text-[#175B37]" |
💡 What: Added aria-labels and focus styles to icon buttons in AgentCard.
🎯 Why: Improve accessibility for screen readers and keyboard users.
♿ Accessibility: Added aria-labels,
aria-hiddento nested SVGs, and keyboard focus rings.PR created automatically by Jules for task 10546121150991294942 started by @bobdivx