Skip to content

Instantly share code, notes, and snippets.

@ShaiqAhmedkhan
Created January 29, 2020 12:38
Show Gist options
  • Save ShaiqAhmedkhan/2b417514c6631b686e493deaf626ba66 to your computer and use it in GitHub Desktop.
Save ShaiqAhmedkhan/2b417514c6631b686e493deaf626ba66 to your computer and use it in GitHub Desktop.
Stack(
children: <Widget>[
Align(
alignment: Alignment.center,
child: RotationTransition(
turns: _repeatingAnimationLong,
child: GalaxyWay(),
),
),
Align(
alignment: Alignment.center,
child: ScaleTransition(
scale: _loopingAnimationShort.drive(_scaleCurve),
child: RotationTransition(
turns: _repeatingAnimationShort,
child: Text(
"🚀",
style: TextStyle(fontSize: largeIconSize),
),
),
),
),
Align(
alignment: Alignment.bottomLeft,
child: SlideTransition(
position: _loopingAnimationShort.drive(_slideCurve),
child: RotationTransition(
turns: _repeatingAnimationShort,
child: Icon(
Icons.star,
color: Colors.white,
size: smallIconSize,
),
),
),
),
Align(
alignment: Alignment.bottomLeft,
child: SlideTransition(
position: _loopingAnimationShort.drive(_reverseSlide),
child: RotationTransition(
turns: _repeatingAnimationShort,
child: Icon(
Icons.star_half,
color: Colors.white,
size: smallIconSize,
),
),
),
),
Align(
alignment: Alignment(0.75, 0),
child: RotationTransition(
turns: _repeatingAnimationLong,
alignment: Alignment(-10, 0),
child: RotationTransition(
turns: _repeatingAnimationShort,
child: Container(
height: 30,
child: Image.asset('assets/earth.jpeg',))
),
),
),
Align(
alignment: Alignment.bottomLeft,
child: TimerStopper(
controllers: [
_repeatingAnimationLong,
_repeatingAnimationShort,
_loopingAnimationShort,
_loopingAnimationLong,
],
),
),
Align(
alignment: Alignment.bottomRight,
child: Flying(
controllers: [
_loopingAnimationShort,
],
),
),
],
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment