-
Notifications
You must be signed in to change notification settings - Fork 1.2k
docs: clear up relative position confusion #8102
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
base: main
Are you sure you want to change the base?
Conversation
@@ -59,3 +59,17 @@ let {visuallyHiddenProps} = useVisuallyHidden(); | |||
|
|||
<div {...visuallyHiddenProps}>I am hidden</div> | |||
``` | |||
|
|||
## Gotchas |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
better section title? use inline alert?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Caveats?
@snowystinger I think this gotcha has a bit different root cause than what you described. I'm almost certain #5094 and #8081 are both caused by the issue I described here https://filip-wachowiak.vercel.app/blog/default-absolute-positioning-in-a-scroll-container TLDR is that interactive elements inside a visually hidden class work weird when focused in a scroll container in chrome |
I didn't go into details, but I'm happy to adjust it if you think there is a clearer message here. |
Closes #5094
followup to #8091 so that people hopefully don't forget the position relative in the future
We can't handle this in our RAC components and we can't handle it if someone uses VisuallyHidden on its own. So it makes sense that it should be documented
✅ Pull Request Checklist:
📝 Test Instructions:
🧢 Your Project: