zeba_academy_scroll_physics_lab 0.0.1
zeba_academy_scroll_physics_lab: ^0.0.1 copied to clipboard
A powerful Flutter package for custom scroll physics, bounce & friction tuning, multi-direction scrolling, and real-time physics editing.
๐ zeba_academy_scroll_physics_lab #
A powerful Flutter package for custom scroll physics, fine-tuned motion control, and interactive physics editing.
Design fluid, natural, and highly customizable scrolling experiences across all platforms.
โจ Features #
- ๐ฏ Custom Scroll Physics Engine
- โ๏ธ Bounce & Friction Tuning
- ๐ Multi-Device Scroll Support (Touch, Mouse, Stylus, Trackpad)
- ๐งช Real-time Physics Editor UI
- ๐ High-performance & lightweight
- ๐ฆ Clean architecture & extensible design
๐ฆ Installation #
Add the dependency to your pubspec.yaml:
dependencies:
zeba_academy_scroll_physics_lab: ^0.0.1
Then run:
flutter pub get
๐ Usage #
1. Import #
import 'package:zeba_academy_scroll_physics_lab/zeba_academy_scroll_physics_lab.dart';
2. Basic Example #
final controller = PhysicsController();
ListView.builder(
physics: CustomScrollPhysics(config: controller.config),
itemCount: 50,
itemBuilder: (_, i) => ListTile(title: Text('Item $i')),
);
3. Enable Multi-Direction Scroll #
MaterialApp(
scrollBehavior: MultiDirectionScrollBehavior(),
home: MyHomePage(),
);
4. Add Physics Editor (Live Tuning) #
PhysicsEditor(controller: controller);
โ๏ธ Configuration #
Customize physics using PhysicsConfig:
PhysicsConfig(
friction: 0.02,
bounceFactor: 0.6,
minFlingVelocity: 50,
maxFlingVelocity: 8000,
);
๐ง Architecture #
| Layer | Responsibility |
|---|---|
| Models | PhysicsConfig |
| Core | Custom physics engine |
| Controller | State management |
| Widgets | Physics editor UI |
| Behavior | Multi-device scrolling |
๐งช Testing #
Run tests:
flutter test
All core physics behaviors and controllers are fully tested.
๐ Use Cases #
- ๐ฎ Game-like scroll experiences
- ๐ฑ Advanced UI/UX animations
- ๐ Scroll tuning tools
- ๐งช Physics experimentation
๐ฃ๏ธ Roadmap #
- โ Physics presets (iOS, Android, Gaming)
- ๐ Free-axis scrolling (2D scroll)
- ๐ Debug overlay (velocity, friction graphs)
- โก Performance benchmarks
๐ค Contributing #
Contributions are welcome!
- Fork the repository
- Create a new branch
- Commit your changes
- Open a pull request
๐ License (GPL v3) #
This project is licensed under the GNU General Public License v3.0.
About Me #
โจ Iโm Sufyan bin Uzayr, an open-source developer passionate about building and sharing meaningful projects. You can learn more about me and my work at https://sufyanism.com/ or connect with me on https://www.linkedin.com/in/sufyanism
Your all-in-one no-bloat hub! #
๐ Explore cutting-edge resources in coding, tech, and development at zeba.academy and code.zeba.academy.
Zeba Academy is a learning platform dedicated to coding, technology, and development.
โก Visit: https://zeba.academy โก Learn: https://code.zeba.academy โก YouTube: https://www.youtube.com/@zeba.academy โก Instagram: https://www.instagram.com/zeba.academy/
Thank you for visiting! ๐