A curated collection of interactive, production-ready button animations built entirely with the Flutter SDK.
The focus of this project is on advanced animation techniques using AnimationController, CustomPainter, Matrix transforms, custom shaders, and physics-inspired motion—without relying on any third-party animation packages.
| Particle Storytelling | Typography That Tells a Story |
|---|---|
![]() |
![]() |
| Elemental Download Button | Morphing Share Button |
![]() |
![]() |
- Showcase advanced Flutter animations and Flutter UI design.
- Explore micro-interactions and physics-driven motion.
- Learn and demonstrate complex Flutter animation examples in public.
- Build reusable, high-performance animation patterns for the community.
This repository is structured as an ongoing series of "Episodes." Each episode focuses on a unique interaction design.
A highly kinetic share button demonstrating complex state choreography and gesture-driven interactions.
- The Morph: Shrinks from a pill into a central hub.
- The Bubble Break: 4 social platform bubbles slide out into an arc using
easeOutBackspring physics. - The Vacuum & Drop: Selecting an icon vacuums rejected bubbles back and drops the chosen icon into a checkmark morph.
A physics-driven download button featuring fluid dynamics and CustomPainter rendering.
- The Elements: Three distinct physics themes—Water, Fire, and Toxic Sludge.
- The "Wetting" Border: A dynamic gradient shader instantly colorizes the container border exactly where the liquid touches it.
- Surface Reflection: A semi-transparent wet gloss trace travels along the highest peaks of the sine waves.
- Physical Feedback: Features non-linear download stuttering (
TweenSequence), pressure expansion, and final settling inertia.
A collection of "Action-Aware" typography components where the text animation physically explains the button's purpose.
- Meaningful Idle States: Each button breathes or pulses intuitively (Download's opacity wave, Submit's forward lean, Login's vault squeeze) to hint at its action before a tap.
- Physics-Driven Storytelling: Features a staggered slingshot shoot for Submit, a gravity data-drop for Download, and a 3D vault-door matrix fold for Login.
- 3-Phase Execution: Smoothly transitions through Start -> Process (e.g.,
Downloading...) -> Completion states. - The Success Pulse: Uses micro-interactions like a 4%
elasticOutscale bump upon completion for premium tactile feedback.
A custom physics engine built entirely with CustomPainter to create meaningful particle transformations.
- Delete (Disintegration): The button compresses under tension, cracks, and violently shatters into 80 heavy geometric shards.
- Like (Chaos to Order): 120 particles explode randomly, hit a collision boundary, and algorithmically snap into a perfect Cardioid (Heart) curve.
- Upgrade (Energy Overload): A glowing aura draws 150 particles from deep space directly into the center of the button, triggering a blinding shockwave transformation.
- 3D Flip Button
This repository demonstrates practical Flutter motion design techniques such as:
AnimationControllerorchestration- Staggered animations
CustomPainterandCustomClipper- Matrix transforms and 3D effects
TweenSequencefor non-linear motion- Physics-inspired motion (springs, inertia)
- Canvas drawing and Shaders
- Gesture-driven interactions
- Zero External Dependencies: Built strictly using the core Flutter SDK.
- Feature-First Structure: Animation logic, painters, widgets, and reusable components are separated for maintainability.
- Hardware Accelerated: Uses GPU-friendly transforms (
Transform.translate,Transform.scale) where appropriate to keep animations efficient.
lib/
├── core/ # Constants, colors, and themes
├── features/ # The Episodes (each isolated)
│ ├── morphing_share_button/
│ │ ├── animations/
│ │ ├── widgets/
│ │ └── screen/
│ └── liquid_fill_button/
├── shared/ # Common widgets like the HomeScreen
└── main.dart
- Flutter & Dart
AnimationController&CurvedAnimationCustomPainter& Canvas APITweenSequence
- Clone the repository:
git clone https://github.com/shahtushar-dev/flutter_button_animations.git
- Navigate to the directory:
cd flutter_button_animations - Get the dependencies:
flutter pub get
- Run the app:
flutter run
Feel free to explore the source code, reuse ideas in your own projects, or contribute new animation concepts through pull requests. Whether you want to improve Flutter custom widgets, add new Flutter micro interactions, or optimize existing effects, all contributions are welcome!
Built with ❤️ for the Flutter Community.



