Calm on first load
An icon starts in the state you give it. A list of liked posts doesn’t burst into hearts as it scrolls into view. Only a change animates.
40 animated icons for Jetpack Compose and Compose Multiplatform. Pass a state and the icon animates. No Lottie files, no XML, no assets.
compose-motion-icons:icons:0.3.0
Playground
Hover an icon to preview its next state. Click it to try every state, colour and stroke, then copy the Kotlin.
Loading the playground
This browser can’t run the live playground.
It needs WebAssembly GC: Chrome 119, Firefox 120 or Safari 18.2 and newer. Here is every icon animating instead.
Your icons already change state.
Now they can show it.
Why it holds up
An icon starts in the state you give it. A list of liked posts doesn’t burst into hearts as it scrolls into view. Only a change animates.
Tap twice quickly and the icon turns back from where it is, taking only the time the remaining distance needs. No jumps, no queue.
Every icon has a description that follows its state, like “Like” and “Unlike” or “Cart, 3 items”. With system animations off, icons switch instantly.
Wrap a screen in FreezeMotionIcons and icons jump straight to their state, so Paparazzi and Roborazzi never capture one halfway through.
Install
Step 1
In settings.gradle.kts, inside dependencyResolutionManagement.
repositories { maven("https://jitpack.io") }Step 2
In your module’s build.gradle.kts.
implementation("com.github.zainkhalid91.compose-motion-icons:icons:0.3.0")Step 3
The icon animates every time the state changes.
HeartIcon(liked = isLiked)FAQ
No. Every icon is drawn in Compose code on a 24 by 24 grid. There are no JSON, XML or image files to ship.
Android, desktop (JVM) and web (Wasm), through Compose Multiplatform. This page runs the library itself in your browser.
No. An icon starts in the state you pass it. It only animates when that state changes afterwards.
Yes. Each icon takes color, size and strokeWidth. Set them once for a whole screen with ProvideMotionIconStyle, which also controls the animation speed.
Yes. With system animations turned off, icons switch to their new state instantly, and looping icons like the equalizer stand still.
Wrap the content in FreezeMotionIcons. Icons jump straight to their state and looping icons stop, so every capture is the same.
Yes. It is MIT licensed, free for personal and commercial use.
Open an issue on GitHub. New icons arrive in themed batches until the set reaches 50.