Very interested in y'all's thoughts on this
Chrome 108+ has experimental support for CSS Toggles, and now you can implement components like Tree views, Tabs, Carousels, and more with CSS. Without the input `:checked` hack. Make CSS great again!🥳 Demo: codepen.io/yisi/pen/RwydJJa @Una @jh3yy @argyleink
24
17
1
190
so my immediate thought: what about accessibility? are you now maintaining state in CSS, and why would you even want to do it that way? this seems just as bad of a weird hack/incorrect use of technology as the :checked hack...
5
1
2
10
Figuring out if we can have default ARIA roles inferred from toggle usage patterns is the next thing I'm looking to implement in the toggles prototype. There's a bunch of notes in github.com/tabatkins/css-tog… though I'm not sure how comprehensible they'll be.
2
1
1
Right now this is experimental; don't want to ship if it's bad for accessibility. I don't think that means every use of toggle must have perfect accessibility (I don't think that's possible), but it should lead to the web being more accessible than it is today.

Oct 17, 2022 · 7:24 PM UTC

2