sunny_core_widgets library

Classes

AdvancedRouteSettings
AndroidModalOpener<T>
AppBarTitle
AuthModalArgs
AutoLayout
Body0Text
Body1Text
Body2Text
Body3Text
ChipButton
CoreWidgetsProvider
CupertinoModalOpener<T>
CupertinoSlidingSegmentedControl2<T>
An iOS 13 style segmented control.
CupertinoVisualStyle
DesktopModalOpener
DesktopPageLayout
DividingLine
DragHandle
ErrorText
Form0Theme
HandleSheet
Headline3Text
Headline4Text
HeroText
HorizontalSpace
HoverEffect
IdArgs<R>
InputText
InputWidgetsProvider
IntlCore
KeyArgs<R>
KeyboardVisibility
Calls builder on keyboard close/open. https://stackoverflow.com/a/63241409/1321917
LargeTitle
Layout
LayoutInfo
LinkText
MessageLookup
MobilePageLayout
ModalOpener
Describes how to open modal windows on the various platforms. A new modal opener can be registered by using Modals.register
ModalOverlayLayout
Modals
ModalScrollPhysics
NestedNavigatorContainer
NonOpaqueCupertinoPageRoute<T>
Creates a platform-appropriate page route.
NormalText
PageSectionHeaderText
PlaceholderText
PlatformCard
PlatformCardArgs
PlatformCardTheme
PlatformLayoutInfo
PlatformListTile
PlatformModalScaffold
PlatformNetworkImage
PlatformSegmentControl
PrimaryText
Provided
ProvidedBox<T>
A container that sits at the top of the provider tree that can be updated from within the tree.
ProviderBuildContextResolver
Px
RawSunnyColors
ResponsiveConstraint
ResponsivePageLayout
ResponsiveSliverConstraint
ResponsiveSwitcher
RichTextBuilder
Allows for building rich text using the known styles
RouteExtensions
ScrollerArgs
SecondaryText
SimpleSliverList<W>
SlidingTab
Snapshots
StyledText
SunnyColorData
Implementation of color spec.
SunnyColors
SunnyIntl
SunnyIntlDelegate
SunnyMargin
SunnyPad
SunnyPage
SunnyPageLayout
SunnyPageState
SunnyResponsivePage
SunnyResponsivePageState
SunnyRouterFactory
SunnyRouting
SunnySpacing
List of font styles based on reliveit naming conventions. This can be easily applied to a material or cupertino theme.
TabRouteArgs
Tappable
TertiaryText
TextWidgets
Themes
TileSubtitle
TileTitle
TitleText
VerticalSpace

Extensions

AppRouteExtension on AppRoute<dynamic, RouteParams>
AppRouteGoNavigationExtension on AppRoute<R, P>?
AppRouteKeyNavExtension on AppRoute<R, KeyArgs<T>>
AppRouteMatchExtensions on AppRouteMatch<dynamic, RouteParams>
AppRouteMatchGoExtension on AppRouteMatch<dynamic, RouteParams>
AppRouteNavigationExtension on AppRoute<R, P>
AppRouteTypedExtension on AppRoute<R, P>
AutoLayoutBuilderExt on AutoLayout
AutoLayoutConversion on MainAxisAlignment
AutoLayoutSingleExt on AutoLayout
BorderSideExtensions on BorderSide
BrightnessExt on Brightness
BuildContextDeviceScreenTypeExt on BuildContext
BuildContextNestedNavigator on BuildContext
BuildContextProvidesExtension on BuildContext
BuildContextRichText on BuildContext
BuildContextThemes on BuildContext
ColorResolver on Color
ColorToWidgetExt on Color
CupertinoDynamicColorToWidgetExt on CupertinoDynamicColor
CupertinoVisualStyleBuildContext on BuildContext
DataServiceBuilder on DataService<X>
FlexiDateFormatters on FlexiDate
FRouterExtensions on FRouter
FutureWidgetExt on Future<T>
IterableWidgetConstraint on Iterable<Widget>
MModelIdArgsExt on X
MSchemaRefExt on MSchemaRef
MSchemaRefKeyExtension on MSchemaRef
PlatformSegmentControlExt on PlatformSegmentControl
RecordDataServiceBuilder on RecordDataService<X, KType>
ResolverInitToProviderExt on Inst<T>
RichTextBuilderTrippiExt on RichTextBuilder
RouteCast on Route
SizedBoxExt on SizedBox
SizeExtension on num
SnapshotExtensions on AsyncSnapshot<X>
StreamWidgetBuilder on Stream<T>
SunnyColorExt on SunnyColors
SunnySpacingToEdgeInsets on SunnySpacing
SunnyWidgetHeroExtensions on Widget
TabPageExt on FRouter
TextStyleColorExt on TextStyle
we run points calculations off this
TextStyleMergeExt on TextStyle?
TextStylePlatformExt on TextStyle
TextStyleWidgetBuilderExt on TextStyle
TextThemeApplyEachExt on TextTheme
ThemesExt on Themes
TypeToRouteExt on dynamic
WidgetConstraint on Widget
WidgetDragHandleExt on Widget
WidgetListExtensions on List<Widget>
WidgetMaybeWrap on Widget
WidgetSpacingExt on Widget

Properties

CoreWidgets CoreWidgetsProvider
getter/setter pair
defaultDarkTheme ThemeData
final
defaultFontFamily String
getter/setter pair
defaultLightTheme ThemeData
final
InputWidgets InputWidgetsProvider
getter/setter pair
loadingIndicator Center
final
messages MessageLookup
final
nestedGlobalKey GlobalKey<NavigatorState>
final
platformBrightness Brightness
no setter
sliverLoadingIndicator SliverToBoxAdapter
final
sunnyColors SunnyColors
no setter
sunnySpacing SunnySpacing
no setter
sunnyText → SunnyTextTheme
no setter

Functions

assumeWidget(BuildContext context, dynamic item) Widget?
bottomSheetModal<T>(BuildContext context, WidgetBuilder scrollBuilder, {bool displayDragHandle = true}) Future<T?>
buildSliverBox(WidgetBuilder builder) WidgetBuilder
centerColumn(Iterable<Widget> children, {Color? color}) Widget
centerRow(Iterable<Widget> children) Widget
column(Iterable<Widget> children, {Color? color, WidgetWrapper? wrapper, Widget ifEmpty()?}) Widget
consume<T>(BuildContext context, [void exec(T value)?]) → T?
cupertinoMenuOpener<T>({bool useScaffold = true}) OpenMenu<T>
defaultClearIcon() Widget
defaultTypeaheadOptionBuilder({Widget? title, Widget? leading, Widget? trailing, VoidCallback? onTap, Widget? subtitle}) Widget
divide(Iterable<Widget> widgets, Widget? wrapped) List<Widget>
form0Theme(Themes themes, Brightness brightness) ThemeData
ForScreenSize<T>(BuildContext context, {T? mobile, T? tablet, T? desktop, T? defaultValue}) → T
hpad(Widget child, [bool white = true]) SunnyPad
initializeMessages(String localeName) bool
User programs should call this before using localeName for messages.
kErrorHandler(BuildContext context, Object? err, StackTrace? stack) Widget
kLoader() Widget
memoizeScrollBuild(WidgetBuilder builder) WidgetBuilder
memoizeScrollToNon(WidgetBuilder builder) WidgetBuilder
memoizeWidgetBuilder(WidgetBuilder builder) WidgetBuilder
nestedModal<T>(BuildContext context, WidgetBuilder scrollBuilder, {bool displayDragHandle = true, required PathRouteSettings? settings}) Future<T?>
openAndroidMenu<T>(BuildContext context, {required WidgetBuilder builder, bool displayDragHandle = true, bool dismissible = true, bool draggable = true, PathRouteSettings? settings, double? width, double? height, bool expand = false, bool useRootNavigator = true, bool nestModals = false, Constraints? constraints}) Future<T?>
openDesktopMenu<T>(BuildContext context, {required WidgetBuilder builder, bool displayDragHandle = true, bool dismissible = true, bool draggable = true, PathRouteSettings? settings, double? width, double? height, bool useRootNavigator = true, bool expand = false, bool nestModals = false, Constraints? constraints}) Future<T?>
OptionalBuilder(BuildContext context, {WidgetBuilder? mobile, WidgetBuilder? tablet, WidgetBuilder? desktop, WidgetListBuilder? desktops}) List<Widget>
Does runtime analysis to determine whether to build any of the provided widgets.
pad(Widget child) SunnyPad
PlatformNetworkImageProvider(dynamic url) ImageProvider<Object>
PlatformPageRoute<T>({WidgetBuilder? builder, RouteSettings? settings, bool maintainState = true, bool fullscreenDialog = false, bool nonOpaque = true, bool forceMaterial = false, bool inPageRoute = false}) PageRoute<T>
Creates a platform-appropriate page route.
Reprovide<T>(BuildContext context, {bool listen = true, required Widget child}) Widget
ResponsiveItem<R>(BuildContext context, {ResponsiveExpression<R>? mobile, ResponsiveExpression<R>? tablet, ResponsiveExpression<R>? desktop, R? defaultValue}) → R
ResponsiveList<R>(BuildContext context, {ResponsiveExpression<R>? mobile, ResponsiveExpression<R>? tablet, ResponsiveExpression<R>? desktop, ResponsiveListExpression<R>? desktops, ResponsiveListExpression<R>? tablets}) List<R>
richTextBuilder(BuildContext context, RichTextBuild build) Widget
richTextInvertedBuilder(BuildContext context, void build(RichTextBuilder builder)) Widget
row(Iterable<Widget> children) Widget
sameWidget(Widget input) Widget
shim(Widget child) SunnyPad
showPlatformMenu<T>(BuildContext context, {required WidgetBuilder builder, bool useScaffold = true, bool displayDragHandle = true, bool dismissible = true, bool draggable = true, Constraints? constraints, PathRouteSettings? settings, double? width, double? height, bool expand = false, bool useRootNavigator = true, bool nestModals = false}) Future<T?>
simple<R, P>(Widget builder()) → WidgetHandler<R, P>
SingleLineText(String? text, {TextAlign? alignment, TextStyle? style}) Text?
sizeExtensions() → void
sliverBox(Widget widget, [bool wrap = true]) Widget
sliverBoxes(Iterable<Widget> widgets) List<Widget>
sliverLoaderFn() Widget
slivers({Widget? child}) Widget
spaced({required List<Widget> children, EdgeInsets? space}) List<Widget>
stack(Iterable<Widget> children, {AlignmentGeometry? alignment}) Widget
tappable<R>(Widget child, {FutureOrTappableCallback? onTap, Key? key, double pressOpacity = 1.0, BuildContext? context, String? routeName, dynamic arguments, void callback(R? result)?}) Widget
Enforces HitTest.opaque and removes parameters
textOrNull(dynamic txt, {TextAlign? alignment, TextStyle? style, Color? color, bool wrap = true, int? maxLines}) Widget?
verticalSpacer(double size) Widget
vpad(Widget child, [bool white = true]) SunnyPad
widgetWithDragHandle({Widget? child}) Widget
wpad(Widget child) SunnyPad
wrap({Iterable<Widget>? children, double runspacing = 5, double spacing = 10}) Widget

Typedefs

DataServiceWidgetBuilder<X> = Widget Function(X data, DataService<X> service)
DataServiceWidgetBuilderWithContext<X> = Widget Function(BuildContext context, X data, DataService<X> service)
DynamicContextFactory = dynamic Function(BuildContext context)
FutureBuildCallback<T> = FutureOr<T> Function(BuildContext context)
FutureOrTappableCallback<T> = FutureOr<T> Function()
FutureTappableCallback<T> = FutureOr<T> Function(BuildContext context)
HoverBuilder = Widget Function(bool isHover)
KeyboardVisibilityBuilder = Widget Function(BuildContext context, Widget? child, bool isKeyboardVisible)
LayoutConfigure = void Function(AutoLayout container)
LongPressCallback = FutureOr Function(BuildContext context)
Lookup = dynamic Function(dynamic val)
MessageIfAbsent = dynamic Function(String message_str, List args)
ModalArgsBuilder<P extends RouteParams> = P Function(ScrollController? controller)
Passes the ScrollController to the route args
ModalOpenerOverride = ModalOpener? Function(BuildContext context, {bool useScaffold})
OnGenerateRoute<T> = Route<T> Function(RouteSettings settings)
OpenMenu<T> = Future<T?> Function(BuildContext context, {required WidgetBuilder builder, Constraints? constraints, bool dismissible, bool displayDragHandle, bool draggable, bool expand, double? height, bool nestModals, PathRouteSettings? settings, bool useRootNavigator, double? width})
OpenModal<T> = Future<T?> Function(BuildContext context, {required WidgetBuilder builder, bool dismissible, bool displayDragHandle, bool draggable, bool expand, double? height, bool nestModals, PathRouteSettings? settings, bool useRootNavigator, double? width})
OpenSettings = Future<bool?> Function(BuildContext context)
PlatformScreenInit = void Function(PlatformLayoutInfo platformLayoutInfo)
RecordDataServiceWidgetBuilder<X, KType> = Widget Function(X data, RecordDataService<X, KType> service)
RecordDataServiceWidgetBuilderWithContext<X, KType> = Widget Function(BuildContext context, X data, RecordDataService<X, KType> service)
ResponsiveExpression<R> = R Function(BuildContext context)
ResponsiveListExpression<R> = List<R> Function(BuildContext context)
ResponsiveMaxWidth = double Function(SizingInformation sizing)
ResponsiveSliverMaxWidth = double Function(BuildContext context, SliverConstraints sizing)
RichTextBuild = void Function(RichTextBuilder builder)
ScreenInit = void Function(BuildContext context, LayoutInfo layoutInfo)
SimpleWidgetBuilder = Widget Function()
SliverWidgetBuilder<T> = Widget? Function(BuildContext context, T item)
SliverWrapper = Widget Function(Widget widget)
StyleAdjuster = TextStyle Function(TextStyle theme)
StyleExtractor = TextStyle? Function(TextTheme theme)
SunnyPageLayoutFactory = SunnyPageLayout Function(SunnyPageState state)
TabChanged = void Function(BuildContext context, int change)
ThemeDataBuilder = ThemeData Function(Brightness brightness, TextStyle inputStyle, TextStyle placeholder1)
TypeaheadOptionBuilder = Widget Function({Widget? leading, VoidCallback? onTap, Widget? subtitle, Widget? title, Widget? trailing})
WidgetContextDataBuilder<I> = Widget Function(BuildContext context, I input)
WidgetContextFactory = Widget Function(BuildContext context)
WidgetDataBuilder<I> = Widget Function(I input)
WidgetErrorBuilder = Widget Function(BuildContext context, Object err, StackTrace? stack)
WidgetFactory = Widget Function()
WidgetListBuilder = List<Widget> Function(BuildContext context)
WidgetListContextFactory = List<Widget> Function(BuildContext context)
WidgetListFactory = List<Widget> Function()
WidgetListScrollerContextFactory = List<Widget> Function(BuildContext context, ScrollController controller)
WidgetOrLoaderBuilder<I> = Widget Function(I? input, SimpleWidgetBuilder loader)
WidgetScrollerContextFactory = Widget Function(BuildContext context, ScrollController controller)
WidgetWrapFn = Widget Function(WidgetBuilder builder)
WidgetWrapper = Widget Function(Widget widget)