Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Accessibility: Focusable div at beginning of modals #48903

Open
Watso196 opened this issue May 13, 2024 · 2 comments
Open

Accessibility: Focusable div at beginning of modals #48903

Watso196 opened this issue May 13, 2024 · 2 comments

Comments

@Watso196
Copy link

Reproduction link

Edit on CodeSandbox

Steps to reproduce

  1. Open modal
  2. Use keyboard Tab key to move focus
  3. Note that focus is "lost" (become invisible) after moving past the OK button, due to focus moving to the hidden div at the top of the modal

What is expected?

Focus should stay within the modal, moving between interactive elements, and should not disappear at any point

What is actually happening?

Focus visually disappears when landing on the non-interactive and invisible hidden

at the top of the modal

Environment Info
antd 5.17.0
React 17
System Mac Sonoma 14.4.1 (23E224)
Browser Version 124.0.6367.158 (Official Build) (arm64)

This is technically a failure of the Focus Visible and Focus Order WCAG guidelines:
Focus Visible: https://www.w3.org/WAI/WCAG21/Understanding/focus-visible.html
Focus Order: https://www.w3.org/WAI/WCAG21/Understanding/focus-order.html

@scottapow
Copy link

Looks like there was an attempted resolution for this issue here but it still persists for me after 5.15.0. You might consider moving this issue to the rc-dialog repo @Watso196

@Watso196
Copy link
Author

Watso196 commented May 22, 2024

Gotcha, thanks @scottapow! I've submitted this issue to the rc-dialog repo
react-component/dialog#429

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants