ookami-kb / storybook_flutter

A storybook for Flutter widgets.
https://pub.dev/packages/storybook_flutter
MIT License
284 stars 63 forks source link

feat: add initialTheme/onThemeChanged #99

Closed witwash closed 1 year ago

witwash commented 1 year ago

Added support for saving theme mode.

witwash commented 1 year ago

@ookami-kb can you please look at this one? Tests should be working. Could be due to inconsistency or something :-/

ookami-kb commented 1 year ago

I wouldn't make it part of the storybook. Mainly, I don't like adding a dependency on shared_preferences.

We can instead add the configuration for the plugin, e.g. initialTheme and onThemeChanged, and it would be up to the user to save/restore it.