OpenWebAdvocacy / website

Source code for the Open Web Advocacy website.
https://open-web-advocacy.org/
MIT License
33 stars 24 forks source link

Add focus trap to language version modal #188

Closed gericci closed 16 hours ago

gericci commented 1 week ago

Type of Change

Summary

As the dialog for language versions has any focus trap, keyboard users will "leave" the dialog and continues to tab on main page, when she should stay on the dialog until it is closed

Details

Add a script to prevent keyboard users to leave the dialog before closing it

rejhgadellaa commented 1 week ago

Shouldn't the <dialog /> element take care of that when it's in modal-mode? That automatically makes the document inert (except for the dialog).

jessbudd commented 1 day ago

Has this issue already been completed? Focus trap appears to be working correctly for me

https://github.com/user-attachments/assets/51999f7a-6222-41ec-9c31-258e77ea530d

sbesh91 commented 16 hours ago

Closing this issue as it seems to work as expected.