0

In other words, how to change Drawer default background color using ThemeData while setting light / dark themes for MaterialApp widget.

I have searched for something like drawerTheme but ThemeData constructor does not have such property. Changing backgroundColor etc doesn't work either. This topic suggests wrapping Drawer with Theme and use canvasColor which thankfully works, but I'm searching for clean solution to achieve this using ThemeData without need for wrapping every single Drawer in my application.

This is Drawer with pitch black background color

Stahp
  • 972
  • 1
  • 9
  • 16

1 Answers1

0

I'm blind. The answer is in the very thread I've linked. The solution to the problem is changing canvasColor property of ThemeData.

Stahp
  • 972
  • 1
  • 9
  • 16