Keyboard-accessible resize

A response to “Image comparison slider *without* JavaScript?” on Mastodon.

Note

Message thread

Matthias Zöchling wrote on

In reply to: @mia@front-end.social, @zachleat@zachleat.com, @Jamessw@mastodon.cloud, @Edent@mastodon.social.

resize, and some A11Y fallbacks:
cssence.com/2022/pure-css-image-compare

Matthias Zöchling wrote on

In reply to: @Jamessw@mastodon.cloud.

Good question. Given that dragging a resizeable element in a CSS grid adjusts the whole grid gives us possibilities we’ve last had in the olden days (which IIRC were also not keyboard-accessible):

<frameset cols="120, *">

How could it work? Like how an <input type="file">’s button is stylable via the ::file-selector-button?

James Stuckey Weber wrote on

In reply to: @CSSence@mas.to.

Yeah, I think having it be a `part-like` pseudo element, like ::after, ::before, or ::file-selector-button would make sense. It could be interesting to have it anchored to the resized element, so you could do things like height: anchor-size(height); position-area: left to position and size it.

Get involved

Have your say on Mastodon, or simply share this thread.