build method
Widget that performs animation from right to left
Implementation
@override
Widget build(BuildContext context) {
return Container(
padding: index == 0
? const EdgeInsets.only(top: 10)
: const EdgeInsets.only(top: 0),
child: Opacity(
opacity: 1 - value,
child: Transform(
alignment: Alignment.centerLeft,
transform: Matrix4.identity()
..translate(210, 0, 0)
..rotateY(value / 0.5)
..translate(-210, 0, 0),
child: child,
),
),
);
}