x-collapse does not hide collapsed content from the accessibility tree #2277
-
Hi, Big fan of Alpine! Thanks for all the time that has been put into it :) I was checking out x-collapse and noticed that visually collapsed content is not hidden/removed from the accessibility tree, so keyboard users can tab to focusable elements that should be hidden, and the content may be announced to screenreader users. At the moment we just hide content with One way to hide the content safely would be to add a The .space-y-1>:not([hidden])~:not([hidden]) {
--tw-space-y-reverse: 0;
margin-top: calc(.25rem * calc(1 - var(--tw-space-y-reverse)));
margin-bottom: calc(.25rem * var(--tw-space-y-reverse))
} You could also add |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 9 replies
-
I agree this is a big problem, I had to remove most of my uses of |
Beta Was this translation helpful? Give feedback.
-
@calebporzio I've raised a PR for this one :) #2353 |
Beta Was this translation helpful? Give feedback.
@calebporzio I've raised a PR for this one :) #2353