Is there still any point to most styles in visually hidden classes in '26?
-
Is there still any point to most styles in visually hidden classes in '26?
Any point to shrinking dimensions to `1px` and setting `overflow: hidden` when `clip-path` to nothing via `inset(50%)`/ `circle(0)` reduces clickable area to nothing? And then no `1px` dimensions means no need for `white-space`.
Because based on this article https://vispero.com/resources/the-anatomy-of-visually-hidden/ I just don't see why any styles other than `position: absolute` + `clip-path` to nothing would still be necessary.
-
Is there still any point to most styles in visually hidden classes in '26?
Any point to shrinking dimensions to `1px` and setting `overflow: hidden` when `clip-path` to nothing via `inset(50%)`/ `circle(0)` reduces clickable area to nothing? And then no `1px` dimensions means no need for `white-space`.
Because based on this article https://vispero.com/resources/the-anatomy-of-visually-hidden/ I just don't see why any styles other than `position: absolute` + `clip-path` to nothing would still be necessary.
@anatudor that seems good enough to me. I guess the rest is just old habits.
-
Is there still any point to most styles in visually hidden classes in '26?
Any point to shrinking dimensions to `1px` and setting `overflow: hidden` when `clip-path` to nothing via `inset(50%)`/ `circle(0)` reduces clickable area to nothing? And then no `1px` dimensions means no need for `white-space`.
Because based on this article https://vispero.com/resources/the-anatomy-of-visually-hidden/ I just don't see why any styles other than `position: absolute` + `clip-path` to nothing would still be necessary.
@anatudor the stick in the mud has been odd/unusual behaviour in safari when it comes to focusable elements. if that is now resolved, and no other browsers have since regressed to not exposing content to AT ... sure
-
@anatudor the stick in the mud has been odd/unusual behaviour in safari when it comes to focusable elements. if that is now resolved, and no other browsers have since regressed to not exposing content to AT ... sure
@patrick_h_lauke Any link on that? All I could find was Safari ≤ 15 removing visually hidden elements from focus order

-
@patrick_h_lauke Any link on that? All I could find was Safari ≤ 15 removing visually hidden elements from focus order

@anatudor not off the top of my head, but ... you'd need to test (including testing with various browser/screen reader combinations). also noting how safari/ios often behaves differently from safari/macos ...
-
@anatudor not off the top of my head, but ... you'd need to test (including testing with various browser/screen reader combinations). also noting how safari/ios often behaves differently from safari/macos ...
(no access to any apple device, I've gone around the block asking, but nobody has anything like that here)
-
@anatudor not off the top of my head, but ... you'd need to test (including testing with various browser/screen reader combinations). also noting how safari/ios often behaves differently from safari/macos ...
@patrick_h_lauke @anatudor IIRC there is this one https://bugs.webkit.org/show_bug.cgi?id=163658
-
@patrick_h_lauke @anatudor IIRC there is this one https://bugs.webkit.org/show_bug.cgi?id=163658
@Thain @patrick_h_lauke Wait, what am I missing? How is that related to visually hidden elements?
(I just wanted to replace the text content of a span with an icon, no links or navigating anywhere else on the page involved)
-
@Thain @patrick_h_lauke Wait, what am I missing? How is that related to visually hidden elements?
(I just wanted to replace the text content of a span with an icon, no links or navigating anywhere else on the page involved)
-
@anatudor @Thain beyond that, there used to be weird inconsistencies even just for hiding text, where some browser/SRs would take visual hints ("oh, this element has zero width/height...") to then also not expose content at all in the accessibility tree ("...so i also won't expose it for screen readers"). and that has historically been finicky and prone to regressions/quirky behaviours. so that part would also need to be tested thoroughly (and may regress again at any point)
-
@anatudor @Thain beyond that, there used to be weird inconsistencies even just for hiding text, where some browser/SRs would take visual hints ("oh, this element has zero width/height...") to then also not expose content at all in the accessibility tree ("...so i also won't expose it for screen readers"). and that has historically been finicky and prone to regressions/quirky behaviours. so that part would also need to be tested thoroughly (and may regress again at any point)
@patrick_h_lauke @Thain Yes, that's exactly what I don't get. Simplifying to the bone = excludes things that historically caused problem like width and height.
So what's the problem then and how are the historical problems triggered by the simplification? Where I am not touching the width and height?
-
R ActivityRelay shared this topic