My favourite animation trick: exponential smoothing (2023)
lisyarus.github.io
lisyarus.github.io
If you've used CSS transitions you'll have encountered the problem this solves. Okay, my duration is 400ms -- but why 400? Shouldn't it depend on how far it has to move?
As others have noted, exponential smoothing has a different problem, that it asymptotically approaches but never quite reaches its destination. The obvious fix is to stop animating when the step gets below some threshold, but that's inelegant.
When using a similar method for inertial scrolling, I've found it useful to add a (pseudo-)friction term. This offsets the exponential, and effectively works as a minimum speed. Here it is in Desmos: https://www.desmos.com/calculator/98ufbuzxhj
This is off the cuff, but you might be able to fix this as follows: Interpret exponential smoothing as a ODE on the distance to the target. Call that distance D. Then exponential smoothing is the Euler update for dD/dt=-C*D. (the constant C>0 being a speed parameter) The issue you bring up is basically the fact that the solutions to the ODE are D(t)=A*exp(-C*t), which is asymptotic to zero as t->oo, but never reaches zero. Now, the fix is to replace the ODE with one that goes to zero in finite time. e.g. dD/dt=-C*sqrt(D). (Solutions are half-quadratic. i.e. they are quadratic for a bit then stay zero once you hit zero.) The Euler update for this is stateless like you wanted.
Why? It's simple, easy to implement and validate, and provides the desired visual impact. Seems perfectly elegant to me.
It seems to me that the "speed" parameter in the exponential function has the same issue, does it not?
For these cases, the exponential lerp trick is very useful, and not universally known. There are many games (some of mine included!) that use the less correct linear lerp and run into trouble with their animations feeling completely off once somebody runs the game on a 240 Hz monitor, or anything different from the 60fps that used to be standard.
For this reason, I appreciate the article. It's usually hard to access this type of hyper-specific knowledge, as it is most often passed as an "apprentice-style" oral tradition from the senior people on a team to the more junior members.
Think about the breaker switches on the electrical consumer unit on your house, or the kind of switches you often find on analog synths or other audio gear, generally stuff that's going for a particular aesthetic. I have a small Hughes & Kettner guitar amp that has two of these switches that are very satisfying to use[0].
When you use these kinds of switches in real life there's some initial resistance, and then they suddenly snap into the new position because of the way they're spring loaded. This is more closely modelled by the cubic function than it is by either the sqrt or the exponential smoothing function.
Other than that absolute nitpick, I really enjoyed the piece. It well illustrates how animation can enhance a user experience when done well (with, for example, an appropriate easing function) or alternatively detract from it and be quite jarring if not implemented thoughtfully (thinking particularly of the linear interpolation examples).
[0] This does somewhat depend on the type of toggle switch, although even the variety that you find on something like a Minimoog (this isn't some sort of gear flex, by the way - I don't own one of these!) exhibit this "resist then snap to the new position" behaviour that makes them so enjoyable to flick.
The odd thing is that humans do not always understand acceleration. Don't run away from a fire uphill, in a belief it travels as fast (semi constant) across level ground: fire accelerates up hills.
Kids rapidly learn the rate of movement across ground for a thrown ball but not always just how fast it will be moving under gravity when it smacks into your hands.
* Moves slowly to about 75% of the way there while you hold the touch/click
* Snaps the rest of the way on release
I’m not sure what this could mean in terms of UX though. Maybe the setting is actually applied or saved at the end.
Or it could be part of an “are you sure?” dialogue. The setting is applied as you hold, but you can hit escape to undo before it snaps into place.
input:checked + .slider:active:before {
transform: translateX(8px);
transition: 1s;
}
input:not(:checked) + .slider:active:before {
transform: translateX(18px);
transition: 1s;
}So while your at it: also make it possible to slide the toggle. Or just use checkboxes.
Anyway, point is: potentially more of an "it's new to me" thing than an "elderly" thing.
https://metafizzy.co/blog/initial-demos/
https://metafizzy.co/blog/math-time-resting-position/
https://metafizzy.co/blog/particle-to-slider/
https://metafizzy.co/blog/flickity-begins/
Especially this demo: https://codepen.io/desandro/pen/myXdej
This technique isn't just useful for switches. Nor will you use a <canvas> element for a switch. Nor will you have 20 parallel requestAnimationFrame loops running on the entire site. Or intentionally broken elements. The site also doesn't have optimizations where the rendering stops once the delta is too small — or probably dozens more of small tweaks that could make this production ready.
The comments here show that people either haven't read the article and are making assumptions, or can't see the forest for the trees. Or are just simply so biased and cynical that they need to share their (unprofessional) opinion in order to appear smart.
Since when has HN turned into Reddit?
Read at least the last paragraph of https://news.ycombinator.com/newsguidelines.html
Certain topics on HN can induce commenting behaviour among seasoned HN users often attributed to Reddit users, including, but not limited to:
- being contrarian without fully reading, understanding or contextualizing the article or comment in question
- weaponizing downvotes
- being overly cynical, lowering the overall quality of the discussion
- repeating, or tersely acknowledging what has been said by most upvoted comments in order to gain more upvotes
That said, it’s not a good idea to make assumptions about behavior or why voting is happening, it lowers the overall quality of the discussion to state those assumptions or complain about comments, and it generally doesn’t work here to tersely acknowledge something to get upvotes. I don’t know what weaponizing downvotes means, but I haven’t seen much downvoting here that can’t be explained by comments being either wrong about something or rude about something.
In my experience, it does often help to patiently respond to contrarians without negative judgement and explain how and why you value good animation tricks, and what problems they solve. That will probably earn you upvotes much faster trying to repeat or agree with another comment.
That has been happening for a while, but people are not talking about it because it's explicitly against hn guidelines. Gee, I wonder why.
Re HN becoming like Reddit..
Perhaps there is a generic 'cynical feeling' in the air with technology, with feelings of distrust about the intentions of governments and corporations over their use of the profound technology that is appearing, and how this is being constructed with the intention to constrain and manage the individual, rather than enabling greater freedom.
Maybe you could help the user to better distinguish the ON/OFF states by also colorizing the whole switch element, not only that "disc" (as it is done in Vuetify.js, for example, using the "color" prop: https://vuetifyjs.com/en/components/switches/
Looking at the map example, I find the cubic smoothing way “calmer”. The exponential one feels a bit hectic and I am wondering if it’s an American thing. It’s got a “wheez” quality that is annoying to me, but that reminds me of hyper cartoons like powerpuff girls.
It’s still all very subtle…
.-------.
\_/ \_/
The two low energy states are the on/off positions.Next, we want there to be some friction.
Lastly, we imagine the switch being moved by a mechanism that moves linearly, and is connected to the switch by an invisible spring or rubber band.
As the motion begins, the invisible linkage spring compresses and the switch moves only a little. Then it snaps out of the potential valley and moves across the plateau. Finally it snaps into the other valley, with a bit of overshoot.
The property of this is that you won’t find any discontinuity in any degree of derivatives. Ie it is smooth in the mathematical sense. If you want to make changes from a constant function (such as not moving at all) to something else (start moving), then this smoothness is a nice property.
You can be salty about excessive use of animations in modern UI all day long, but you have to respect that level of commitment.
I wish the author had linked to the wikis for either of those things up front so people who had heard of it already (and know why you probably don't want to use it for your UI) could move on.
Does it? Looks much better to me, and preferred to waiting for a animation to be given more time to speedup while looking "smooth" (they seldom seem to be given the same time as instant or linear animations, do they? For some reason we have to be forced to enjoy them in half time).
In fact I'd take the "instant toggle" in a heartbeat too. Real life toggles don't "exponentially smooth" from one side to the other either.
Animations, or anything else really, should only be used to improve things. Ask what the problem is, not what cool solution I should implement. It's ok to go to town if the page is artistic, like your blog, but if I'm filling out a form? Get your art out of here.
It's cool to choose the tools that appeal to your values. It's not cool to advocate for paving the planet in your quest for single-minded efficiency.
But would you still prefer it if alternative paved sidewalk is 5 times shorter AND you need to walk between same two points of interest multiple times per day, everyday?
Beauty can be expressed with the toggle's design, with the window decoration, with the colors, with the wallpaper, choice of font, and so on.
No need to be expressed with an animation.
If your car did a little "song and dance" everytime you started it up that you had to wait to be able to drive it off, it would get annoying really fast.
You just highlight the data that has changed and have an "Apply" button to save those changes.
Just respect prefers-reduced-motion when implementing animations and everyone is happy.
I liked the article and its demonstrations because I learnt something.
Personally, I switch off animations whenever possible, preferring snappy action over flashy effects. But they have their use, for example in the rubber band effect which would be quite jarring without motion smoothing.
This reminds me of Medium spending months to change the underline beneath a descender: https://medium.design/crafting-link-underlines-on-medium-7c0...
It would be my deepest displeasure to bring a button toggle animation to production that requires more than CSS.
Quick example I found:
https://hudecz.medium.com/how-to-create-a-pure-css-toggle-bu...
Easing/Smoothing is possible with transition-timing-function.
https://www.w3schools.com/cssref/css3_pr_transition-timing-f....
Of course CSS could do it with less JS, but this would have been a totally different post.
Also, that page uses 100% of the CPU in Firefox.
Text selection also doesn't seem to work... is it all Canvas maybe?
If the site doesn't even load, does it matter what function you use for the toggle in the settings page?
one is how to handle user inputs to a camera/world with inertia while moving whith a lot more variables to set for a certain desired feel, (why no long taps/mousedown to speed up the movement).
While the button is just easing a fixed animation between two states with no intermediate input.
Also what happens to the binary state of the app if the animation can be reversed before reaching final state, this is opening a can of worms for no obvious reason.
Check boxes work just fine without a form btw: https://stackoverflow.com/a/50012963
You can use pretty much any widget to store a boolean state. A select? It works. Radio buttons? Works. Checkbox? Of course. Typing "1" or "0" in a text input limited to integers between 0 and 1 inclusive? Why not. But semantics matter, and so does the principle of least surprise. Nowadays users expect an immediate result when toggling a toggle button. Not as much when they toggle a checkbox.
This (for example) performs exponential smoothing:
new += (target - old) / 4;
That's it!(The exponentially smoothed animation looks weird to me, in any case.)
Imagine my disappointment when I found that the iPhone slider for mute didn't smoothly slide the sound volume to silence, as per the visual effect, but snapped it to zero just like the Android switch.
;)
Because it allows you to /cancel/ the action.. click, 'oops don't want that' drag mouse/finger out and release. No action taken. User is in control. Amazing.
No, no it doesn't. Not at all.
It's a MAP. It's there explicitly to display information, If I'm moving the map such a distance that an instant effect might not rely the information that place X is above place Y then yes, maybe an animation is in order, since that gives me more information, but every single iteration after the first one is worse, way worse, and the last one is one of the worst of them, feels like trying to drag your feet through mud.
The second one is clearly a bug though.
Unfortunately it is, just a fancy thing that too often makes it worse or just focuses on the wrong thing.
Like in this case, what exactly is "going on" that requires this visual delay? It looks worse vs the original instant response, why does the user need to care about intermediate movement of this binary toggle?
Then this is the fanciness that detracts from solving the major flaw of these sliders: you can't easily tell whether it's off or on
Nothing. It's a technical demonstration. The delay is also overemphasized to make the difference more apparent.
> The this is the fanciness that detracts from solving the major flaw of these sliders: you can't easily tell whether it's off or on
That's because they don't represent anything. Toggles don't always represent on or off, either-- they could represent a binary choice between any number of things.
> Unfortunately it is, just a fancy thing that too often makes it worse or just focuses on the wrong thing. > It looks worse vs the original instant response, why does the user need to care about intermediate movement of this binary toggle?
Putting aside the functionality that animations can add, because others have addressed it, even "feel" does matter to most users. Many people would choose soft-close cabinets over regular spring loaded hinges even if noise wasn't a concern. You'd never see them in a commercial kitchen, though-- people just move too fast and that extra bit just gets in the way. It would be rather absurd for someone in a professional kitchen to assume home cooks have the same requirements and use cases for cabinets that line cooks do. Similarly, people who spend most of their days doing technical things using technical tools made by and for technical people interpret interfaces differently than most people. To developers, UIs are a little part of an application to expose the functionality to users, and the less distance between the application and the user, the better. But more often than not, that approach yields results far more useful to someone with a working mental model of how software operates under the hood. To most people,the UI is the application, and the application is an appliance. Having smooth interactions that 'feel' nice to use are much more desirable.
As someone with a good amount of professional experience both as a developer and a designer, I'm consistently surprised by how quick so many developers are to assume their personal usage habits, osmosis-gained knowledge from projects, and folk wisdom about design trumps the expertise of seasoned credentialed professionals in the field. The reason most end-user-facing FOSS projects (that don't have foundation-funded UI teams like Blender or Mozilla) are used almost exclusively by other developers is because non-technical users usually find the experience unpalatable at best, and unusable at worst.
Most "non-technical" people use computers, especially desktops, in a professional setting. Navigating those UIs is part of their jobs and they will spent hours upon hours doing so.
Pretty animations may make a good first impressions but they get old and annoying very fast. It is a huge mistake in UI design to only optimize for smooth on-boarding of new users and not for long term productivity.
> The reason most end-user-facing FOSS projects (that don't have foundation-funded UI teams like Blender or Mozilla
Blender has great UI because they are dog-fooding their own software through blender studio. Meaning because they are the users and develop UI based on their own needs, contradicting your theory.
Firefox UI has gotten significantly WORSE over time and the browser is becoming irrelevant based on market share. Now that is not all the fault of the UI but it is still worth noting that the height of firefox popularity was when it had a very power-user friendly UI that all that fancy "UI experts" would hate. Maybe they should replace the "foundation-funded" UI team.
As for commercial software, modern UI is so bad that many "non-technical" users actively hate using computers and feel absolutely powerless when errors occur. Modern UI is actively user-hostile.
Firefox is irrelevant today because the supposedly highly sophisticated users decided based on feel.
Smooth animation performance was a major point of iOS over Android for years.
I see plenty of evidence of sophisticated users deciding based on the factors you dismiss.
I prefer programs I perceive as "snappier" -- and to me, a part of "snappiness" is choosing not to animate things unnecessarily.
Yes, but they still reason about those interfaces totally differently. This isn't a quantitative difference in competence, it's a qualitative difference in approach.
> Pretty animations may make a good first impressions but they get old and annoying very fast. It is a huge mistake in UI design to only optimize for smooth on-boarding of new users and not for long term productivity.
Animations that stick out as 'being animated' are rarely desirable. I assure you that you don't notice most of the animations you benefit from in your usage.
> The reason most end-user-facing FOSS projects (that don't have foundation-funded UI teams like Blender or Mozilla
> Blender has great UI because they are dog-fooding their own software through blender studio. Meaning because they are the users and develop UI based on their own needs, contradicting your theory.
Do you have any actual evidence for the assertion that Blender's UI designers don't actually drive the usability of the software?
> Firefox UI has gotten significantly WORSE over time and the browser is becoming irrelevant based on market share. Now that is not all the fault of the UI but it is still worth noting that the height of firefox popularity was when it had a very power-user friendly UI that all that fancy "UI experts" would hate. Maybe they should replace the "foundation-funded" UI team.
You're substituting your opinion for fact. Mozilla's design team publishes a lot of stuff. If you think it's wrong, there's lots of specifics available for you to counter.
> As for commercial software, modern UI is so bad that many "non-technical" users actively hate using computers and feel absolutely powerless when errors occur. Modern UI is actively user-hostile.
This is a common trope among developers who think their feelings about interface design carry more weight than the research that actually tests these things. It holds about as much weight as any other feelings vs facts argument.
I assure you, I do notice them. I am disabling them everywhere I can. I disable them in my Desktop Environment, I disable them on my Android smartphone. I am way more productive without them.
Now, I don't hate animations per se. On the contrary as I dabble in game dev I find them crucial to "juice up" a game. They have their place but that is not productivity software that people are forced to use daily. They are for play not work.
> This is a common trope among developers who think their feelings about interface design carry more weight than the research that actually tests these things. It holds about as much weight as any other feelings vs facts argument.
Many open source devs are users of their software. You are making a false dichotomy where developer are some special creatures with totally different needs. I like what I like. There is no such thing as an "average user". People have different needs. Making software for the lowest common denominator will create UI that will be miserable for everyone to use.
Now I am willing to listen to actual academic studies about UI design and productivity but your acting like some corporate internal studies are actually legit science is silly. We all know this things are are more drive by corporate politics.
I think most people would trade opacity and fancy buttons for MS Teams to be able to load in under a minute.
Fixed that for you.
It's a paradox. If you don't make it look fancy, smooth, and appealing, you lose out to those that do. Even if you have a better product, that doesn't mean you can sell it on merits of being more technically efficient. Especially to more casual consumer or to business heads to make the purchases.
besides, the minute loading times aren't because it's caching all those animations and assets. That's a different division with different problems. Probably a mix of security checks, inefficient networking, and _maybe_ some choice in framework like Electron as a distant 3-5th (not that Teams uses Election).
No weird colours or anything. Just mostly standard controls, unless it's necessary to create a custom one.
Exactly! Too many people think that their personal preference is the best. Sometimes, the best solution is to have plain HTML where the user chooses their favorite font and size, like in the early Netscape era. However, that's not always the case.
And I think most users would prefer software that does stuff instantly. Attaching little animations to everything is just silly and distracting. It only happens because someone had nothing better to do but still had to look busy. These things almost universally degrade the interface and I've yet to see the actual benefit of them, aside from the fact that they draw attention to themselves and make people think "someone put some work into that". When you think about it, that is the opposite of good interface design. A good interface is one you do not notice – it puts as little as possible between user and machine.
Some people like the unrealistic jumping of no animation, which is totally fine. Some people want it to "feel like a computer" not how things actually behave in the real world. It's taste. Animations that are too long or too noticeable are bad taste. But animations themselves are not bad.
Hmm, users certainly prefer software that's fast, but I don't know about "instantly".
Feedback is important. A button that gently clicks so you know it took effect is better than a touch sensor with no feedback. Animations can serve the same purpose as that click. (And of course they can be overdone, just like a button can be overly stiff or loud.)
User research feels differently, but with numbers.
> These things almost universally degrade the interface and I've yet to see the actual benefit of them
See my point about technical people and their usage perspectives.
> When you think about it, that is the opposite of good interface design.
Having been a professional software designer, I assure you I've thought about this. And explored it, researched it, tested it, prototyped it, interviewed people about it, built it, rebuilt it, and then did it all over again to improve it. Re-read the last paragraph in my comment.
> A good interface is one you do not notice – it puts as little as possible between user and machine.
On second thought, re-read the whole comment.
> I assure you I've thought about this. And explored it, researched it, tested it, prototyped it, interviewed people about it, built it, rebuilt it, and then did it all over again to improve it.
Oh, sorry, I didn't realise I was talking to the world expert on button animations. So do users prefer quadratic or exponential smoothing on their switches?
A good animation is one you do not notice. Subtlety that succeeds in loading off its feedback payload in your brain without exposing the transmission mechanism to the conscious level of perception.
Chances are you are only complaining about the subset of animations that failed to stay under that threshold. Yes, slow, elaborate animations are bad.
Same here, and couldn't agree more. Except that I'm not surprised.
The thing is, developers with this pov have often been exposed to really shitty UIs where there's poor design aesthetics, matched with no understanding of the user's problems, coupled with fancy effects, that end up getting in the way and breaking in subtle ways - and ultimately don't represent what the developer is trying to do.
People have a varying level of being exposed to such UIs, but professional developers, esp. dealing with enterprise portals and internal systems have been really burnt by this.
Sorry to be nitpicky-- I largely agree with your comment-- but I always must point out that interface design is a communication medium, not an aesthetic medium. Like technical writing, it's a communication medium even if there are some secondary aesthetic considerations.
To be fair, developers coming from math and CS backgrounds may not have had any HCI/UX/design training. For those who have, "You are not the user" [1] was drilled in as a foundational concept.
If one segment of your users reports something as a problem, you need to at least try to understand why and whether it is possible to reconcile with what your other users want, or whether in fact your other users also would agree but just haven't been vocal about it.
Is any evaluation of any field you’re not an expert in hubris? Or is it possible to use basic logic to identify contradictions in the assertions made by experts outside your field?
1. Is it when I pushed the toggle, regardless of when animation finishes? 2. Is it when the animation finishes
This is necessary when flipping many toggles on one page and it needs to be done many times over. In case there's no animation, it simple and clear. In case there's animation you need the know is it case 1 or 2. If it's case 2 it will additionally slow you down as you now need to wait until all animations lengths * number of switches toggled has finished.
A dropdown with the words enabled/disabled indicating the state will always be better than a toggle with some subtle animation and colour signalling the state.
They're fine if there's going to be loads of options such as country name, but if its left handed or right handed, I just want to see a toggle/radio button that lets me switch and makes it clear which state its currently in.
> A dropdown with the words enabled/disabled indicating the state will always be better than a toggle with some subtle animation and colour signalling the state.
Oh yeah way better except for not being able to see all of your options or even how many options there are without interacting with it, at least double the number of keystrokes to operate, more cognitive load to parse and operate, not being idiomatic for the interaction, etc. etc. etc. There are lots of uses that dropdowns work better for, but saying they're simply better is asinine.
Spot on. Devs have on average extreme levels of confidence in unrepresentative opinions (space bar heating) and think UI is beneath them.
> FOSS projects (that don't have foundation-funded UI teams like Blender or Mozilla) are used almost exclusively by other developers
Nobody is better at pissing away hard labor like devs. There are these amazing OSS projects with 10ks of man hours invested, that won’t let designers near their cluttered prototype ui, if any. Designers are meme-famous as working for free - harnessing their power in FOSS would be akin to convincing a child to eat ice cream. Yet they’re unable to.
Note this is not only UI, but general theory of mind skills. How many times have you read a README on GitHub where it’s written like the most over-cryptic nonsense, despite being quite general and straight forward projects under the hood? My working theory is UI skills and “explaining things” are fruits from the same tree. Most devs don’t practice it, so they get deep into curse of knowledge territory. Even the smart have blindspots, maybe especially them.
Given how bad UIs in general have become, some scepticism over that expertise is warranted.
To be clear, UIs weren’t all great across the board 20 years ago. But there was a general agreement between UI experts and power users on how a good UI with standard desktop controls should look like and behave, whereas now it’s a mess and there are significant disagreements.
Details?
So? The justification is still substantive. What would change in a real slider that turns real setting on/off?
> delay is also overemphasized
That's only true for those slowed down by a factor of 8. Otherwise it's not, I see the exact same issue in real-world sliders on web sites and in apps.
> Toggles don't always represent on or off, either
But they mostly do, add they do in this case ("turned_on"). The other use cases would have different issues like the choice of colors (green is for on)
Then you overly general description forgets to prove that slower and more confusing control (which some generic non-tech users try to actually slide by holding a mouse button and moving the mouse instead of clicking) is actually preferable because it "feels" nice to them
Also, these > seasoned credentialed professionals in the field.
are the same people who put these garbage sliders in the OS settings menus (as well as maintaining many other common decades-old UI bugs), so color me unimpressed by their credentialed osmosis degrading user experience at scale (poor FOSS designs notwithstanding)
No it's not. Whether or not a design accomplishes its goals is exclusively based on what it's trying to communicate. This is trying to communicate animation curves.
> That's only true for those slowed down by a factor of 8. Otherwise it's not, I see the exact same issue in real-world sliders on web sites and in apps.
What you notice in apps is probably noticeable because it was done poorly. In the vast majority of instances, these things are done well so they help your eye adjust but don't stick out as animations.
> But they mostly do, add they do in this case ("turned_on"). The other use cases would have different issues like the choice of colors (green is for on) Then you overly general description forgets to prove that slower and more confusing control (which some generic non-tech users try to actually slide by holding a mouse button and moving the mouse instead of clicking) is actually preferable because it "feels" nice to them
You're substituting assumption for knowledge.
> Also, these > seasoned credentialed professionals in the field. are the same people who put these garbage sliders in the OS settings menus (as well as maintaining many other common decades-old UI bugs), so color me unimpressed by their credentialed osmosis degrading user experience at scale (poor FOSS designs notwithstanding)
Most novices can't distinguish poor practice from poor practitioners from poor general concepts.
The thing about design principles is that the designer picks the one that justifies their decision, which is more like fashion than anything.
For example: Windows 8 swept away shadow, and semi-transparent material in the name of flat design, making it resemble Windows 2.0. Windows 10 brought back shadow. Windows 11 brought back Semi-transparent material and also rounded corners buttons from Windows 2.0.
Gradients have been banished and missing for a decade, but I am waiting for a come-back.
> because these are aspects of the physical world that we already know how to interpert, so can be used "for free" to aid our understanding of the UI.
The above could also apply to more than just shadows, gradients, and momentum.
Skeuomorphic icons help users understand functions but we have shape & outlines resembling hieroglyphs. I doubt we are getting skeuomorphic icons back ever because font icons are just too awesome for designers.
Most real world buttons are elevated off the surface to let us know it is pressable, but digital buttons now just have a white or colored pill shape around it. I can't recall the last time I saw a pill shaped button in the real world.
Well not really, real world buttons are elevated off the surface because of the practicalities of producing buttons and attaching them to a surface, some of the material has to be above the surface and some below for it to clamp on. Buttons are also usually produced as separate components and thus tend to be round or square because it's more mechanically simple and suits the most use cases, labels can be put around the button.
Computers have completely different mechanics, all buttons can be a bespoke size and shape, and they're inherently not tactile, the pill shape is just the easiest way to allow a button with variable width for variable font sized text, because it's easier to put the text on the button itself digitally than irl.
Some UI designers think animations are good, but they are not. They are a clutch that designers who don't know how to design good UIs rely on to indicate what is going on. We have never had faster computers than we do now, but we are collectively spending thousands of hours a day waiting for pointless animations to finish.
Imho animations are not a problem in cases where they do not affect latency. For example a visual click feedback to tell the user that it was registered & is being processed makes sense, especially for situations where the task may take a while. For example Mac OS' "eject drive" button would benefit from this, it has zero visual click feedback while ejecting the drive can take a whole minute for some reason. Yet at the same time Apple simply refuses to remove the 1 second long workspace switch animation even if blocked in the accessibility settings, they only swap the swiping animation with a fading animation.
The problem is that often designers simply don't put any thought into it other than "make it smooth and look nice".
In cases where the animation affects latency between user input and reaction to it there is no animation speed that's fast enough. It will always feel like wading through a swamp.
More like "for the same reason a fish needs a bicycle".
>Not using animations would likely be more taxing on our visual processing
And yet, Windows 2000 era UI was far more intuitive, consistent, and self-discoverable than today's animated, shadowed, gradient-filled, blurry transulcent, momentum-having flat crap.
They put shadows on otherwise flat layers - for gratuitous effect, but also to get back some separation after they've flattenned everything.
And if you expect users to slide, then the slider should reflect the speed of your mouse like a physical control commongly would, not that of some random algorithm, no?
Because the “knob” changes position. Like in the real world, objects can’t disappear in one place, and then instantly appear in another. Animating a UI state change in terms of a move transition can help people to understand how both end-states are logically connected to each other. The animation resembles the mechanics of the slider knob being a “perpetual entity” that can move between two positions, rather than the slider control as a whole being some sort of static icon that is instantly swapped out for another static icon once I click on it.
Whether or not animations are necessary might still be arguable. I suppose it depends on the complexity of the UI control, on personal preference, and certainly also on the general level of technical familiarity of the end-user.
I think that we have tools in the UX toolbox that are less reliant on animations than others, but yeah, if you can get animations to be neat, yet fast it's great unless battery life is also a big concern.
TBH, animations only began to be acceptable to me once I got a high refresh rate screen and a fast computer, before that I knew they were speed bumps for my old hardware and maybe hated them a bit more than they deserved.
Can you tell me which position of the toggle means on? Purple or green.
If you had red or green, which one is on?
Requiring the user to mentally diff before and after states would be like a sailor only confirming captain's orders when explicitly asked "did you understand me?" instead of an unsolicited aye.
Where the "on-state not as clear as with a checkbox" critique gets a resounding comeback is when slider-looking on/off states are introduced only because of fashion, but in a process where the language used in animations (e.g. screen mockup bitmaps) is completely unaware of animations and therefore they only happen if toolkit sliders match exactly. Yeah, don't ask...
Here's how I deal with that, in my app: https://imgur.com/a/6uQnuox
It's accompanied by haptics.
I think I remember some map apps experimenting in that direction, but I consider the locusmaps "magnifying glass" undisputed king of that hill (touch interaction for maps).
I usually dislike animations. I used to disable transitions whereever possible, as they made the UIs feel sluggish. And I still do.
But working on the project made me for the first time really appreciate in practice how much amimations help with understanding. I paid a high price in complexity to add transitions whenever the state of the visual graph changes, and suddenly it was really obvious what was happening. Commits and whole branches were sliding into their new position, and I would go "a-ha! I see" instead of "wtf just happened, what am I looking at now?".
EDIT: Fair warning, it's heavily WIP https://gitlab.com/indigane/visual-git
Minimizing animations are nice for showing you where things “went” when you minimize them. But apart from that, most other UI annimations are just eye candy.
Why do only old nerds complain about this, when today's UIs are so "easy" that every toddler can use the smartphone? Are we just living in the past, getting old; are we the problem, why is our opinion unpopular?
I think other people do feel a vague sense of anxiety using modern software from not quite knowing what all the interaction patterns are. When you click that hamburger menu on the website, what will it do, exactly? But most people from outside the software world just blame themselves for “not being very good with computers”.
The problem is that it’s not fashionable any more amongst designers to use built in controls. Everyone wants to think of themselves like Apple, and build their own beautiful design language. Even if it’s just for their own website or app. And it sort of makes sense given modern apps end up needing to be built for the web, iphone, iPad, Android, and the desktop. It makes sense to tie all of those pieces of software together with a cohesive visual language and style.
I just don't care if my computing experience is beautiful. I care if it's snappy, productive, and reliable.
Agree, that sums my opinion well.
And much software doesn't even look like they preferred eye candy over clarity; it rather looks like they forgot about clarity completely.
You're doing it there too: You're throwing every bad point of every bad UI you ever encountered into a bucket and throw all of that at this article by concluding "Animations in UI are terrible and just bloat everywhere". That's very close to a strawman.
I have worked and AB-tested in UIs for games and such dealing with just that and I would much rather say: Bad UIs are bad, yes. And animations don't help bad UI not being bad. But if you have a good, understandable UI, adding animations smartly - without impeding the user and in subtle fashion - on top of that UI... that can increase the overall aesthetics of the UI a lot and make the UI much more pleasing to use.
My post replied to "checkboxes vs UI toggles", and replying to that aspect was my main point. That's slightly off-topic, of course. It has to do with animations only because checkboxes wouldn't really benefit from animation, whereas toggles are an obscure visual representation for the same control, and adding animation is a feeble attempt to make it somewhat less obscure, even though it doesn't even try to address the main problem: what does toggle "left" and "right" really mean?
I believe checkbox not benefting from animation is a good thing: it's so clear and obvious that you don't need to animate it.
Custom list control: do Home/End buttons work? How to select multiple items, does Shift-Cursorkeys work? Does Ctrl-Click work? Of course not.
Custom text control: does Ctrl-Left/Right for word jumping work? Does Ctrl-Up/Down for paragraph jumping work? Can I select everything with Ctrl-A or does it select the whole website? Can I select everything from cursor until the end with Ctrl-Shift-End work? Does Copy/Paste work at all? (I have never figured out why Copy/Paste in Teams simply doesn't work. Apparently I'm the only one with this problem.)
Custom dropdown control: does Alt-Down work? Can I scroll the list with the usual keys?
If (web) developers would just use standard controls, everything would work the same, and they wouldn't have to reimplement all the basic things from scratch (or not at all). Web devs could write forms that work without megabytes of JavaScript.
Hamburger menus. Those horrible things didn't need to exist even in old times with small monitors and 640x480 (or less) - but now they exist everywhere on my 32" 4K monitor for no reason.
https://stackoverflow.com/questions/44876144/how-to-style-th...
Consider the “kitchen lights” illustration here: https://learn.microsoft.com/en-us/windows/apps/design/contro...
Do you really think a checkbox has the right affordances for this action?
That's the whole point. That's why the primary use of sliders on desktop is opt-out of something no user really wants.
This is often combined with scroll windows with some sliders offscreen and invisible scroll bars.
I think that’s an unpopular opinion. The instant response looks janky, exponential smoothing looks well polished as long as it’s not too slow.
Its like saying a web-page that loads and displays instantly is "janky" versus a web-page with a busy symbol that makes you pause and wait.
If you had 20 of these toggles to check, you would prefer your "janky" version anytime.
It's not a great type of widget for that anyway, as others said. But either way the animation adds nothing except time the designer could have used to think about a better interface.
The snappy "instant" and simple UIs for Windows 95/2000 era were the best, IMO. It might take a bit to get used to non-animated updates it if you have never experienced it before and seem a bit janky, but it doesn't take long and at least for me feels much nicer.
Quarter of a century of "UX experts" and useless animations and transparency and complicating things has resulted in an objectively worse experience. It's slow, clunky, inconsistent, constantly changing, and doesn't even look good. The technical parts of the drawing, scaling, font rendering, color management, etc are much better of course, but not the overall experience.
UI design was of huge importance to the industry (Apple and Microsoft) when GUIs were first coming in, many people were still getting into the world of computers, and many of those who were using them were not comfortable with them. Improving the experience could be worth a fortune in new market. That's why usability, intuitiveness, and consistency were priorities and it was taken seriously as a discipline, there was research, and changes were made with (at least in part) quantitative data and study.
That field of UI design has basically died in the industry now. At least, it is much smaller and less impactful than it was. Most of it seems to have shifted to getting people to look at and interact with things that they otherwise would not have. I guess shiny new things would help with that, maybe that explains the baffling direction things have gone in.
EDIT: BTW., don't take this as criticism of the linked post. Back when I did a bit of graphics programming I loved tinkering around to make things visually pleasing and behave in interesting ways. The post is fun and interesting, and presented in a way that itself is a nice experience and must have taken a lot of work. And I don't think the author was passing it off as an end to end guideline for a user interface design. And I do accept that a lot of people do like more visually interesting and diverse interfaces. They're wrong, of course, but entitled to their opinion (/s)
But the other side of the coin is that, because it is eye-catching, animation can be distracting or annoying.
Adding animation to your UI is like adding salt to your cooking: it's going to be pretty bland without it, but you can also ruin things by going overboard.
> inexperienced people often see poor outcomes as an indictment of a technique, tool, or approach when the practitioner is to blame.
Or they simply realized that so many practitioners are to blame that the distinction barely matters anymore.
You're confidently saying it makes the experience worse but you said you didn't notice a difference when it went away? There's a lot of data out there that says otherwise. Once again, developers use of interfaces differs from regular users as much as professional cooks use of kitchen equipment differs from home cooks. It's very different.
> Or they simply realized that so many practitioners are to blame that the distinction barely matters anymore.
Sorry, no. Most shitty software design is done by developers that assemble interfaces based on their whim, most of the rest are done by developers trying to mimic what they think a designer might do (which most developers mistake for design,) and the small remainder are from either incompetent designers or genuine misfires.
Ask any group of professional photographers how many have tried Gimp in an attempt to avoid Adobe's fees-- almost all of them will say they have. Ask how many actually use it? I'd be shocked to find a single one. Aside from the substandard graphic design tools for things like typography (which are totally reasonably not a focus for the project, especially when Inkscape is solid there,) Gimp is a competent photo editor. Who uses Gimp? Developers that need a photo editor. Developers making software that other developers like to use is not an indicator that they know how to make software that's tolerable for other people.
They use these sliders, realize they could be ambiguous, so add an accessibility setting for the on/off labels.
Then they have these fancy animations where holding a slider even elongates the button "providing feedback", but this is just wasted since your finger is covering the button, and fingers have no eyes!
But still, it's a slider, so you'd expect that if you slide your finger over it, it will move. Not so fast, this only works if your started sliding from the slider, not from a side outside it (which would still work in the "real" world.). But if you start at the slider, then there is no point in sliding, there is simply not enough width for that!
Also if slider's button is to the left and you swipe from right to left, the sliders moves right! Take that, immediate fedback in the opposite direction, massive UX boost in a manner that's unexpected and doesn't make sense! (because it's not a real slider, just a check box of a different form)
One of the language apps (either Hemingway or grammarly) had this issue stepping through search results. As you moved, it would change the colour of the matching text, but slowly and subtly, via animation. That makes it much, much harder to actually spot where, in a wall of text, the match actually is. An instant change is far more visible.
My first thought was that the OS accessibility settings must not be available to websites without a permission toggle because the ad industry is just going to weaponize it and use it against people.
The map example is much more important. With animation, your eyes and brain recognizes a single image sliding around, giving you automatic positional awareness. Without, you eyes and brain recognize a slideshow of independent images, and makes recognizing and navigating the map a conscious effort. By no means an impossible effort, but an entirely unnecessary one detrimental to the user experience.
At the same time, navigation UIs that react as navigation-less updates also tend to have the double-whammy of bad UX in the form of blocking and discarding user input during updates.
Bad UIs are not bad because animations are bad, they're bad because they were made poorly.
Isn't that a problem that UI designes (sorry for generalisation) created by themself? Let's stick to the toggle element. It replaces the classic checkbox.
A "checked checkbox" leaves no doubt. A toggle box does.
It's absolutely not that simple. I actually think that the toggle design is _very_ clever, explicitly because it sidesteps a lot of cultural baggage that comes with existing symbols, and creates its own, fairly unambiguous one.
Do you use "checkmark" to indicate that a choice is selected? In some cultures that indicates "wrong" answer.
https://en.wikipedia.org/wiki/Check_mark
Sure, just use "x" then, right?
In _different_ cultures, that one indicates "no, I do not agree".
That being said, those toggles are imho the wrong choice. Checkboxes (that actually have a check-mark) are nicer because they show a clear "yes" and "no" so I don't have to guess which position means what when it comes to a toggle.
There's still some case of adding a few short animations (microinteractions in todays parlance) to give a bit of polish and indicate concurrency or liveness.
The gold standard used to be to make buttons large enough so they are never fully obscured (for toggles, the label can be included to be part of the button) and to highlight them when pressed and remove the highlight when released. (Like keys on a virtual keyboard mostly still behave.) That way, you have a clear indication of when you press something, and it coincides with what your finger is doing, and doesn’t lag behind.
For UI elements that try to replicate the physical world, such as toggles, switches, even some buttons, I find it that the animation makes the UI easier for the brain to understand.
UI is becoming an art, but most people use computers to get their jobs done. And, to be honest, I still prefer checkboxes.
Physical buttons have measurable response times, along with momentum and bounce. They're pretty quick, but get more noticeable as things get bigger.
https://en.wikipedia.org/wiki/Switch#Contact_bounce
The technique becomes even more powerful with additional degrees of freedom, like when moving the map from the article. It feels a lot better to have your view animate smoothly than jump around discontinuously.
I’m with you though. Most animation in UI is superfluous and annoying, if not down right rage inducing (like when the animation blocks input).
A good example of an animation that I don’t dislike is the window minimize animation on macOS where the window gets “sucked” into the Dock. It’s useful because it relates a “where” that I can keep in my head. I click a button, where’d my window go? Down there, I just saw it get sucked down into the Dock.
Animations are tools. Use wisely, they inform and entertain. Use too much, they become boring.
Or we can go back to normal checkboxes and radio buttons where the on/off state is obvious and no animation is necessary to help people see when they change state.
Actually it does not. Flick switches have travel, click buttons have depth. Electronic buttons have lag, bigger systems have startup time (hence the blinkenlights).
My dishwasher starts in ~3 seconds after I press start. The button travel is so much that I'm never sure whether it registered the press or not until I hear the water pump start pulling water from the pipe.
> It gives me an instantaneous feedback.
It's just because you're touching a button, and feeling the pressure on your fingertip. Nothing is in an "instant" in the world.
And just like its design counterpoint, while some may enjoy the aesthetic, it's actually superfluous and we've mostly moved on.
I get it, it's visual, it's easy to show one's boss domain knowledge; it doesn't do anything for accessibility and the feel (dependable repeatable ui workflow).
https://addons.mozilla.org/en-US/firefox/addon/disable-trans...
If you can't see the difference at normal speed, there is no difference.