-
Notifications
You must be signed in to change notification settings - Fork 3.6k
Closed
Labels
Description
Prerequisites
- I am using the correct version of React-Bootstrap for my version of Bootstrap
- I have searched for duplicate or closed issues
- I have read the contributing guidelines
Describe the bug
While the React Bootstrap modal is open, moving around with the keyboard using Tab, focuses on elements outside of the modal. Pressing TAB while navigating the modal should not result in the focus being put on element outside of the modal.
Expected behavior
A user that use the keyboard to navigate a website and open a modal, should get his focus trapped within that modal until he press 'ESC' or the close button.
To Reproduce
- Navigate to a button opening a modal with TAB
- Hit enter
- Using TAB you can see that the focus gets out of the modal
Reproducible Example
https://react-bootstrap.netlify.app/docs/components/modal
Screenshots
No response
What operating system(s) are you seeing the problem on?
Windows
What browser(s) are you seeing the problem on?
Chrome
What version of React-Bootstrap are you using?
v2.10.4
What version of Bootstrap are you using?
5.3
Additional context
No response