-
-
Notifications
You must be signed in to change notification settings - Fork 18
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
Modal allows background text selection & scroll #19
Comments
A temporary fix inspired by https://github.com/tailwindlabs/headlessui/blob/main/packages/%40headlessui-react/src/components/dialog/dialog.tsx (and a lot of googling):
|
The text is still selectable with Ctrl+A though :( |
Hmmm interesting behavior, I'll take a look Edit:
|
I have tried adding
|
btw, when the modal is wrapped inside |
Right, that went over my head 🤣 so it's not the solution then. Let's see
Well yes but that's an HTML specification, not an ARIA specification actually. There's no mention for managing text selection Edit: |
When the modal window is open, the user can still scroll the background content (via the mouse wheel) or select all text (via Ctrl+A).
To minimally reproduce this:
The issue might be related to tailwindlabs/headlessui#1056
Also maybe it has something to do with the fact that I am using astro js, but I do not think so.
The text was updated successfully, but these errors were encountered: