Fiz o código baseado em um outro post, porém troquei o background color do app bar pelo primarySwatch: primaryGreen(),do themer
theme: ThemeData(
primaryColor: Colors.green[800],
colorScheme: ColorScheme.fromSwatch(
primarySwatch: primaryGreen(),
).copyWith(
secondary: Colors.blueAccent[700],
),
buttonTheme: ButtonThemeData(
buttonColor: Colors.blueAccent[700],
textTheme: ButtonTextTheme.primary,
),
),
MaterialColor primaryGreen() {
return MaterialColor(
0xFF2E7D32,
{
50: Colors.green[50]!,
100: Colors.green[100]!,
200: Colors.green[200]!,
300: Colors.green[300]!,
500: Colors.green[500]!,
600: Colors.green[600]!,
700: Colors.green[700]!,
800: Colors.green[800]!,
900: Colors.green[900]!,
},
);
}