🎨 Palette: Improve LanguageSwitcher accessibility#12
Conversation
- Replaced <span> elements with semantic <button> tags for EN/ES options.
- Added explicit aria-labels for screen reader clarity ("Switch to English", etc.).
- Added focus-visible classes for robust keyboard navigation and hover styles.
- Added aria-hidden="true" to the decorative "/" separator.
- Documented this critical learning in .Jules/palette.md.
- Fixed a minor TypeScript issue with a Link tag causing a build failure.
- Ran lint auto-fixes.
Co-authored-by: Twinber <5513621+Twinber@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. |
💡 What: Replaced non-interactive
<span>tags with semantic<button>elements in theLanguageSwitchercomponent.🎯 Why: To fix a critical accessibility issue where the language options were not focusable via keyboard and lacked semantic meaning for screen readers.
♿ Accessibility: Added
aria-labels to the buttons,aria-hidden="true"to the decorative separator, and implemented robust focus and hover states (focus-visible:outline). Added a journal entry detailing this common anti-pattern.PR created automatically by Jules for task 8066996721401296050 started by @Twinber