matrix4_transform icon indicating copy to clipboard operation
matrix4_transform copied to clipboard

Add an example with AnimatedContainer in ReadMe section.

Open yasinarik opened this issue 6 years ago • 1 comments

Hi, dear Marc!

This package is a lifesaver, thank you! Normally, I needed to use an animation, a controller and all that boilerplate.

I was searching for a way to use the transform: property of the AnimatedContainer since it will save me from all that hustle. Found Matrix4Transform at the superb timing!

There isn't any issue actually but you can advertise this package by showing the animation power. And since it's chainable, I can create very complex animations.

AnimatedContainer(
  duration: animationDuration,
  curve: animationCurve,
  transform: Matrix4Transform()
    .translate(
       x: 0,
       y: !widget.isEditModeActive ? 0 : 40,
     ).matrix4,
  child: widget.child,
)

yasinarik avatar Dec 26 '19 20:12 yasinarik

@yasinarik You should also check out AlignPositioned, AnimatedAlignPositioned and AnimChain in package https://pub.dev/packages/align_positioned which all can use Matrix4Transform.

marcglasberg avatar Dec 27 '19 20:12 marcglasberg