Widgetbook's UI Theme
If you want to change some Widgetbook's UI colors, or want to enforce a specific theme mode, you can do so using these parameters:
Parameter | Description |
---|---|
lightTheme | ThemeData that is used when themeMode is ThemeMode.light |
darkTheme | ThemeData that is used when themeMode is ThemeMode.dark . |
themeMode | Controls which ThemeMode to use. Defaults to ThemeMode.system . |
@override
Widget build(BuildContext context) {
return Widgetbook(
lightTheme: ThemeData.light(), // Custom light theme
darkTheme: ThemeData.dark(), // Custom dark theme
themeMode: ThemeMode.light, // Forcing light mode
// ...
);
}