-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Elements always receiving focus & outline on Safari #2459
Comments
or do I just have to add focus:outline-none wherever i don't want this behavior.. but wouldn't that mess with accessibility? I like having the outline there when I tab to it |
Also experiencing this and would be curious what others are doing |
Hey! This has been discussed previously in #1694, and you can learn about the solution we ended up going with in #2347 👍 Basically because we need to imperatively handle focus in a lot of cases for accessibility reasons, Hope that helps! |
hey @adamwathan, thanks for the reply here I think I'm now running into an issue similar to the one here tailwindlabs/tailwindcss#3842 (comment) I have
is there a way to set the attribute lower down the component tree? or do I just need not use the important setting 🤔 but then the thing is that it's really useful for overriding default styles in react native components (which I'm using nativewind for) |
What package within Headless UI are you using?
@headlessui/react
What version of that package are you using?
@headlessui/react: v1.7.14
@headlessui/tailwindcss: v0.1.3
What browser are you using?
Safari
Describe your issue
In safari, desktop and mobile, my headless ui elements are receiving focus-visible and the associated styling (outline) whenever i trigger them. This doesn't happen on chrome. Here's an example:
on safari
Screen.Recording.2023-04-27.at.12.01.34.PM.mov
on chrome (desired behavior)
Screen.Recording.2023-04-27.at.12.02.59.PM.mov
any help / thoughts ? The same is happening with modal components (first focusable elements gets outline) and tabs (tab list items get an outline)
The text was updated successfully, but these errors were encountered: