simplebar
simplebar copied to clipboard
Focus not visible
Describe the bug When navigating content with the keyboard with the TAB key, all elements receiving focus should indicate this eg. by showing a visible focus ring. Since https://github.com/Grsmto/simplebar/pull/587, the scrollable area can be focused with the keyboard, however it does not have a visible focus indicator.
To Reproduce Steps to reproduce the behavior:
- Go to the Demo page
- Use the TAB key (and SHIFT+TAB) to navigate around the page
- See that the buttons receive a dotted outline when receiving focus
- See that whenever the scrollable container is focus, the focus indicator seemingly vanishes
Expected behavior It should always be visible which element has focus. When the scrollable container has focus, it should have a visible indicator.
Additional context WCAG Success Criterion 2.4.7
Your environment
Software | Version(s) |
---|---|
SimpleBar | 6.2.5 |
Browser | Firefox 121 |
npm/Yarn | N/A |
Operating System | Linux |
Is it actually desired to show a focus ring around a scrollable area?
What happens natively?
If it is focusable, it should have a focus ring. Firefox, which is the only browser currently to make scrollable areas focusable like default (like simplebar does), does show a focus ring when focusing via keyboard. See this article for more background on the accessibility issues.