fix: replace global focus outline removal with :focus-visible for key…#5839
Open
manvirsingh01 wants to merge 1 commit intosugarlabs:masterfrom
Open
fix: replace global focus outline removal with :focus-visible for key…#5839manvirsingh01 wants to merge 1 commit intosugarlabs:masterfrom
manvirsingh01 wants to merge 1 commit intosugarlabs:masterfrom
Conversation
…board accessibility (sugarlabs#5828) - Replace '*:focus { outline: none }' with ':focus:not(:focus-visible)' to hide outline for mouse/touch only - Add '*:focus-visible' rule with visible blue (#0066FF) focus ring for keyboard navigation (WCAG 2.4.7) - Scope range input and backToTopBtn outline suppression to mouse-only Fixes sugarlabs#5828
Contributor
|
✅ All Jest tests passed! This PR is ready to merge. |
zealot-zew
reviewed
Feb 20, 2026
Contributor
zealot-zew
left a comment
There was a problem hiding this comment.
we wouldn't be needing this, since the individual buttons have focus on themselves. There's a reason why it the toolbar Focus was set to None.
The issue is not discussed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Fixes #5828
The CSS rule
*:focus { outline: none; }in css/activities.css removes visible focus indicators from all elements, making it impossible for keyboard users to track which element is focused. This violates WCAG 2.4.7 (Focus Visible).This PR replaces the blanket suppression with a
:focus-visibleapproach that:#0066FF) focus ring when navigating with the keyboard (Tab key)Changes
*:focus { outline: none }with*:focus:not(:focus-visible)+*:focus-visibleruleinput[type="range"]outline suppression to mouse-only via:focus:not(:focus-visible)outline: nonefrom#backToTopBtn(now handled by global rule)How to Test
Before & After