Rocket.Chat.Electron icon indicating copy to clipboard operation
Rocket.Chat.Electron copied to clipboard

fix: Adding support to read the title for server buttons.

Open antm-rp opened this issue 2 months ago • 3 comments

fix: Add support for screen readers to read the servers from left side server list. The fix uses the toolTipContent string, giving the user information about the serverr name as well as the shortcut combination.

Summary by CodeRabbit

  • Bug Fixes
    • Improved accessibility of the server button with enhanced labeling for screen readers and assistive technologies.

antm-rp avatar Nov 11 '25 12:11 antm-rp

CLA assistant check
All committers have signed the CLA.

CLAassistant avatar Nov 11 '25 12:11 CLAassistant

Walkthrough

An accessibility label is added to the server button component by setting the aria-label attribute on the IconButton to the existing tooltipContent. This improves screen reader support without changing any other behavior.

Changes

Cohort / File(s) Change Summary
Accessibility Enhancement
src/ui/components/SideBar/ServerButton.tsx
Adds aria-label={tooltipContent} to the IconButton for improved accessibility and screen reader support

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

  • Quick verification that the tooltipContent is always populated when rendered
  • Confirm aria-label accessibility best practices are followed

Poem

🐰 A button once silent, now speaks with care,
With aria-labels floating through the air,
Screen readers rejoice, no more guessing games,
Our ServerButton now proudly proclaims its name! ✨

Pre-merge checks and finishing touches

✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main change: adding accessibility support (aria-label) to server buttons for screen reader compatibility.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing touches
  • [ ] 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • [ ] Create PR with unit tests
  • [ ] Post copyable unit tests in a comment

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 and usage tips.

coderabbitai[bot] avatar Nov 11 '25 12:11 coderabbitai[bot]

@antm-rp issue : bug fixed as it sees

SDV96 avatar Nov 11 '25 12:11 SDV96