tweener
Tweener는 간단하고 가벼운 Flutter 애니메이션 도구입니다. 누구나 쉽게 사용하는 법을 배울 수 있습니다.
Tweener는 간단하고 가벼운 Flutter 애니메이션 도구입니다
아래는 영문 원문 스냅샷입니다. 최신 내용은 GitHub에서 확인하세요.
Tweener is a simple and lightweight flutter animation tool. Anyone can easily learn to use it.
Install the Tweener https://pub.dev/packages/tweener:
dependencies:
tweener: ^2.2.2
flutter packages get
import 'package:tweener/tweener.dart';
Tweener({"x": 0, "y": 0, "alpha": 0, "custom_prop_abc": 123})
.to({"x": 100, "y": 500, "alpha": 1, "custom_prop_abc": 321}, 2000)
.easing(Tweener.ease.elastic.easeOut)
.onUpdate((obj) {
setState(() {
_x = obj["x"];
_y = obj["y"];
_alpha = obj["alpha"];
_abc = obj["custom_prop_abc"];
});
})
.onComplete((obj){
///
})
.start();
var tween1 = new Tweener(sprite)
.to({x: 700, y: 200, rotation: 359}, 2000)
.delay(1000)
.easing(Ease.back.easeOut)
.onUpdate(update);
var tween2 = new Tweener(sprite)
.to({x: 10, y: 20, rotation: 30}, 2000)
.onUpdate(update);
tween1.chain(tween2);
tween1.start();
To operate widget animations more conveniently, you can utilize the AnimateCon library. This library provides extremely facile implementation methods for animations such as position, scale, and alpha, enabling you to easily create various vivid and interesting animation effects.
Tweener refers to the implementation code of tween.js. They are really great. I want to pay tribute to the original author!
의존성 목록 2 개
{"sdk":"flutter"}{"sdk":"flutter"}사용 목적에 따라 검색하고 개발 활동을 비교한 뒤 원본 저장소에서 요구 사항을 확인하세요.
“A repository is the most basic element of GitHub.”
GitHub Docs — About repositories ↗