AppKitModal
you must wrap your MaterialApp
with a ReownAppKitModalTheme
widget.
Default themes
ReownAppKitModalTheme already comes with 2 default themes.A light option:
ReownAppKitModalColors.lightMode
A dark option:
ReownAppKitModalColors.darkMode
.You can switch between them by toggling the
isDarkMode:
parameter in ReownAppKitModalTheme
like so:
Custom themes
You can define your own light and dark themes by tweakingReownAppKitModalThemeData
parameters. For instance, if you want to change the main foreground and background color you could do:
ReownAppKitModalTheme
’s themeData:
parameter:
Preset theme shortcuts
ReownAppKitModalTheme
comes with default border radiuses but you can override these values by passing your own values to ReownAppKitModalRadiuses()
object and then adding this object to ReownAppKitModalThemeData
’s radiuses:
parameter.
But you can also set no corner radiuses at all by setting this value to ReownAppKitModalRadiuses.square
or everything circular by using ReownAppKitModalRadiuses.circular
If you don’t wrap your
MaterialApp
with a ReownAppKitModalTheme
widget, the ReownAppKitModal
will use the default light theme.ReownAppKitModalTheme
is an InheritedWidget so it comes with a few handy methods for you to use:
Check if the current time is dark:
ReownAppKitModalThemeData
object:
ReownAppKitModalColors
object:
ReownAppKitModalThemeData
object. (More and easier customization options will come in the future)