Hacker News new | ask | show | jobs
by akdor1154 1341 days ago
It's a bit crap that this needs conscious work by developers to implement - I feel like with just a little more thought put into the CSS spec itself, that animations could have defaulted to following the user's OS settings unless the dev explicitly marked them as necessary.

Edit: not meaning to absolve developers of thinking about a11y, or to accuse css spec designers of negligence, just making the point that a system/spec that gets devs to do the right thing by default would be a great thing.

3 comments

Your point is entirely valid. It is just good design to not rely on ever expanding checklist of everything every developers should presumably know - including newbies fresh out of higschool.

If it matters, it should happen by itself unless someone turns it off.

Well, the issue is that since our tools already give us arbitrary power over what the user sees, then of course the developer has to opt-in to either using a subset of tools (e.g. some animation API that the OS can toggle) or implement the override like in TFA.

I don't really think you can force people to use a restrictive animation API (and nothing else) since it would have to generalize over all animation needs. Meanwhile, on iOS, SwiftUI is very far from generalizing over all needs—as an example of what a restrictive set of tools might look like. I don't think it's even possible, and the imperative kit will always have to exist.

unless the dev explicitly marked them as necessary

...which basically all of them will naturally do, because their goals are almost certainly not going to be aligned with yours.