flutter_staggered_animations 1.1.1 flutter_staggered_animations: ^1.1.1 copied to clipboard
Easily add staggered animations to your ListView, GridView, Column and Row children as shown in Material Design guidelines
import 'package:flutter/material.dart';
import 'screens/card_column_screen.dart';
import 'screens/card_grid_screen.dart';
import 'screens/card_list_screen.dart';
void main() => runApp(App());
class App extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
theme: ThemeData(
brightness: Brightness.light,
scaffoldBackgroundColor: const Color.fromRGBO(239, 238, 239, 1.0),
),
home: const HomeScreen(),
);
}
}
class HomeScreen extends StatelessWidget {
const HomeScreen({Key? key}) : super(key: key);
@override
Widget build(BuildContext context) {
return Scaffold(
body: Container(
height: double.infinity,
width: double.infinity,
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: <Widget>[
ElevatedButton(
child: const Text('List Card Test'),
onPressed: () {
Navigator.push(
context,
MaterialPageRoute(builder: (context) => CardListScreen()),
);
},
),
ElevatedButton(
child: const Text('Grid Card Test'),
onPressed: () {
Navigator.push(
context,
MaterialPageRoute(builder: (context) => CardGridScreen()),
);
},
),
ElevatedButton(
child: const Text('Column Card Test'),
onPressed: () {
Navigator.push(
context,
MaterialPageRoute(builder: (context) => CardColumnScreen()),
);
},
),
],
),
),
);
}
}