Realizei o mesmo passo passo do video, mesmo assim não mudou a cor do conteiner
Utilizo a versão do flutter 2.5.2
void main() {
runApp(const BytebankApp());
}
class BytebankApp extends StatelessWidget {
const BytebankApp({Key? key}) : super(key: key);
// This widget is the root of your application.
@override
Widget build(BuildContext context) {
return MaterialApp(
theme: ThemeData(
colorScheme:
ColorScheme.fromSwatch(primarySwatch: Colors.green).copyWith(
secondary: Colors.blueAccent[700],
),
elevatedButtonTheme: ElevatedButtonThemeData(
style: TextButton.styleFrom(
backgroundColor: Colors.blueAccent[700],
),
),
),
home: const Dashboard(),
);
}
}
class Dashboard extends StatelessWidget {
const Dashboard({Key? key}) : super(key: key);
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
title: const Text('Dashboard'),
),
body: Column(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Padding(
padding: const EdgeInsets.all(8.0),
child: Image.asset('images/bytebank_logo.png'),
),
Padding(
padding: const EdgeInsets.all(8.0),
child: Container(
padding: const EdgeInsets.all(8.0),
height: 100,
width: 150,
color: Theme.of(context).primaryColor,
child: Column(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
crossAxisAlignment: CrossAxisAlignment.start,
children: const [
Icon(
Icons.people,
color: Colors.white,
size: 24.0,
),
Text(
'Contacts',
style: TextStyle(color: Colors.white, fontSize: 16.0),
),
],
),
),
)
],
),
);
}
}