zds_flutter library
A library of Flutter components made by Zebra Technologies based on the Zebra Design System, or ZDS.
Classes
- CalendarEvent
- Calendar Event model.
- ComponentDelegate
- Delegate to get translations for these components.
- ComponentDeltaProvider
- Abstract class for the component delta strings
- ComponentLocalisation
- Provides localizations for this library.
- ComponentStrings
- Translated Strings file
- Compression
- Compression Profile
- CustomSlidableAction
- Represents an action of an ActionPane.
- DatePickerDialog
- A Material-style date picker dialog.
- DayDetails
- Model for days used in ZdsDayPicker.
- Dimensions
- Tokens that are used for ZetaSpacing.
- Document
- The rich text document
- FilePickerConfig
- The configuration used in a ZdsFilePicker.
- FileWrapper
- Wrapper around files picked using ZdsFilePicker.
- FlutterSlidableAction
- An action for Slidable which can show an icon, a label, or both.
- GiphyClient
- GiphyClientError
- GiphyCollection
- GiphyDownsampledImage
- GiphyDownsizedImage
- GiphyFullImage
- GiphyGet
- GiphyGetWrapper
- GiphyGif
- GiphyGifWidget
- GiphyImages
- GiphyLanguage
- GiphyLoopingImage
- GiphyMeta
- GiphyOriginalImage
- GiphyPagination
- GiphyPreviewImage
- GiphyRating
- GiphyStillImage
- GiphyType
- GiphyUser
- GiphyWebPImage
- Grid
- Tokens that are used for ZetaGrid.
- IconWithBadge
- Shows an icon with an unread badge.
- ImagePicker
- A button that can be used to select an image and show its preview.
- ImagePickerState
- State for ImagePicker.
- KeyboardDismiss
- Provides functionality so that by tapping on descendant widgets (except textfields) the keyboard is dismissed.
- MonthItem
- Displays the days of a given month and allows choosing a date range.
- MonthItemState
- State for MonthItem.
- QuillController
- QuillEditor
- TileField
- Pairs of data used with ZdsFieldsListTile.
- Typography
- Tokens that are used for ZetaText.
- UnreadBadge
- A widget that shows a badge to display how many unread notifications there are.
- WeekIcon
- Model for weeks that should have leading icons.
- XUri
- Uri wrapper
- ZdsAbsorbPointer
- A widget that absorbs pointers during hit testing.
-
ZdsAdaptiveTransitionPageRouteBuilder<
T> - ZdsAdaptiveTransitionPageRouteBuilder is a custom route builder that adapts the transition animation based on the device's orientation.
- ZdsAnimations
- A collection of animations to be used in Zds applications.
- ZdsAppBar
- An app bar with Zds styling.
- ZdsAvatar
- A circular container used to display a user's profile picture or initials.
- ZdsBackButton
- A back button that will, by default, call Navigator.maybePop when pressed.
- ZdsBlockTable
- A scrollable table with floating headers
- ZdsBlockTableCellData
- Defines a cell in a ZdsBlockTable
- ZdsBlockTableHeader
- Defines a header for a ZdsBlockTable
- ZdsBlockTableRow
- Defines a row in a ZdsBlockTable
- ZdsBorderClipper
- A custom clipper that allows you to clip with different offsets on each side.
- ZdsBottomBar
- A container typically used with Scaffold.bottomNavigationBar, in showZdsBottomSheet.bottomBuilder, or as the last child of a Column that contains an Expanded to ensure ZdsBottomBar stays at the bottom.
- ZdsBottomBarTheme
- Theme for ZdsBottomBar.
- ZdsBottomBarThemeData
- Applies style to any child of type ZdsBottomBar.
- ZdsBottomSheet
- Use showZdsBottomSheet to display any bottom sheets instead of using this widget directly.
- ZdsBottomTabBar
- A ZdsBottomBar used to switch between different views. Typically used as a Scaffold.bottomNavigationBar in a StatefulWidget.
- ZdsBottomTabScaffold
- Scaffold with built in support for bottom tabs.
- ZdsBottomTabScaffoldState
- State for ZdsBottomTabScaffold.
- ZdsButton
- An ElevatedButton with pre-applied Zds styling.
- ZdsCalendar
- An adaptable calendar widget that can be used in a variety of ways, with selectable days and date ranges, as well as event markers and different formats.
- ZdsCard
- A card used to display grouped information and related actions.
- ZdsCardActions
- A widget used to show actions at the bottom of a ZdsCard. It's recommended to use ZdsCardWithActions instead of using this widget directly.
- ZdsCardHeader
- A widget used to create header in a ZdsCard.
- ZdsCardWithActions
- Creates a ZdsCard with two sections, one for the main card content, and another one for status/actions information.
- ZdsCheckableButton
- A circular button that can be checked and that accepts either a string or an icon as a child.
- ZdsCompressor
- Compresses the files based on Compression provided.
- ZdsConditionalWrapper
- ZdsConditionalWrapper is a widget that conditionally wraps its child with a wrapperBuilder based on the provided condition.
- ZdsDashedLine
- A widget for creating dashed line or a container
- ZdsDashedLineCorner
- Corner attributes for the ZdsDashedLine.
- ZdsDashedLineState
- State for ZdsDashedLine.
- ZdsDateRange
- A date range selector that also allows to quickly change the range selected by jumping to the next or previous set of dates.
- ZdsDateRangePickerDialog
- A Material-style date range picker dialog.
- ZdsDateRangePickerTile
- A DateRange picker tile that allows to select the from and to dates separately. This can be used if we want to allow the user to select all the dates before a certain date, or all the dates after one.
- ZdsDateRangePickerTileForm
- A DateRange picker tile that allows to select the from and to dates separately with Form validation.
- ZdsDateRangeState
- State for ZdsDateRange.
- ZdsDateTimePicker
- A widget that allow to select a date, a time, or both.
- ZdsDateTimePickerState
- State for ZdsDateTimePicker.
- ZdsDateTimeRange
- Encapsulates a start and end DateTime that represent the range of dates.
- ZdsDayPicker
- A widget that allow to select days.
-
ZdsDropdownList<
T> - A DropdownButtonFormField with Zds style and behavior.
-
ZdsDropdownListItem<
T> - Defines an item to be used in a ZdsDropdownList
-
ZdsDropdownListState<
T> - State for ZdsDropdownList.
- ZdsEmpty
- Creates a message about no results being returned.
- ZdsExpandable
- A component that can be collapsed and uncollapsed.
- ZdsExpansionTile
- A tile that can be expanded and collapsed to reveal further information.
- ZdsExpansionTileState
- State for ZdsExpansionTile, used to handle the on demand expansion and collapsing of the tile
-
ZdsFadePageRouteBuilder<
T> -
A custom
PageRouteBuilder
class that creates a new route with a specified builder function. -
ZdsFieldsListTile<
T> - A tile showing a list of properties with their respective values.
- ZdsFileCompressPostProcessor
- Compressors for mobile devices
- ZdsFileEditPostProcessor
- Editors used to edit only image files & to launch other types of files
- ZdsFilePicker
- Shows a component that can be used to select files and display their previews.
- ZdsFilePickerController
- A controller used with ZdsFilePicker to keep track and use the selected files.
- ZdsFilePickerState
- State fot ZdsFilePicker.
- ZdsFilePostProcessor
- abstract class to process file actions for all processors.
- ZdsFilePreview
- Creates a preview of a file.
- ZdsFileRenamePostProcessor
- used to rename a file before compression.
- ZdsFileSize
- Text widget showing size of the file
- ZdsFloatingActionButton
- Widget that creates an FAB following Zds theming. Note that MD3 introduced a new FAB not yet implemented in Flutter, so this integration might change in the future
- ZdsHorizontalList
- Makes a horizontal ListView that sizes itself to its children.
- ZdsHtmlContainer
- A container widget for displaying HTML content with optional features.
- ZdsIcons
- Identifiers for the supported Zebra icons.
- ZdsIconTextButton
- A widget that creates a Large icon button with text.
- ZdsImageCropPostProcessor
- Editors used to edit only image files & to launch other types of files
- ZdsImages
- A collection of Images and SvgPictures to be used in Zebra applications.
- ZdsIndex
- A component used to show status information, like index, order, or state, in a very small space.
- ZdsInfiniteListView
- Wrapper around a ListView.builder with Zds styling and functions for fetching new items when the user scrolls to the bottom of the list.
- ZdsInfiniteListViewState
- State for ZdsInfiniteListView.
- ZdsInformationBar
- A bar used to display status information.
- ZdsInputBorder
- Border used for input components, such as TextField to apply a Zds style.
- ZdsInputDecoration
- An extension of InputDecoration that applies Zds styling.
- ZdsInputDialog
- A dialog with a textfield and built-in validation.
- ZdsInputDialogState
- State for ZdsInputDialog.
- ZdsLabel
- A label typically used to showcase status information.
- ZdsList
- Creates a ListView with predefined parameters that match Zds styling and behavior.
- ZdsListGroup
- A component that groups items within a ZdsList, eliminating padding between them.
- ZdsListTile
- List tile with Zds styling.
- ZdsListTileTheme
- Theme for a ZdsListTile using Zds style.
- ZdsListTileWrapper
- This Widget takes in the following parameters:
- ZdsMenuItem
- A menu item used in ZdsNavigationMenu.
- ZdsModal
- A widget that can be passed to showDialog to warn the user of a potentially destructive action, like deleting a file. Can be used to obtain confirmation that they want to perform said action.
- A menu for navigation to other parts of the app or to other apps.
- / Label used above a ZdsNavigationMenu.
- Defines a button for ZdsBottomTabBar or ZdsVerticalNav. Used in ZdsBottomTabBar.items.
- ZdsNestedFlow
- This widget can be used for nested flows where some parent widget has to be made available to all of its descendants. For example, a provider that needs to be made available to all routes below it.
- ZdsNestedFlowState
- State for ZdsNestedFlowState.
- ZdsNetworkAvatar
- A circular container used to display a user's profile picture fetched from the internet.
-
ZdsNoAnimationPageRouteBuilder<
T> -
A custom
PageRouteBuilder
class that creates a new route with a specified builder function. - ZdsNotificationTile
- A component used to show a notification with read/unread message details.
- ZdsPopOverIconButton
- An icon button with a popover.
-
ZdsPopupMenu<
T> - Creates a popup menu.
-
ZdsPopupMenuItem<
T> - A component used to create the options that appear when using ZdsPopupMenu.
-
ZdsPopupMenuState<
T> - State for ZdsPopupMenu.
- ZdsProfile
- A component used to show a snapshot of someone's profile.
- ZdsPropertiesList
- A list of properties with their respective values.
- ZdsQuillDelta
-
ZdsQuillDelta represents a wrapper around the Quill's
Document
to offer additional functionalities like conversion from and to HTML. - ZdsQuillEditor
- A custom widget for the Quill editor.
- ZdsQuillEditorPage
- Represents a Quill editor page.
-
ZdsRadioItem<
T> - A class that ZdsRadioList.items must extend.
-
ZdsRadioList<
U extends ZdsRadioItem> - Creates a list of radio buttons with labels. Tapping anywhere on the list tile selects the item.
-
ZdsRadioListState<
U extends ZdsRadioItem> - State for ZdsRadioList.
- ZdsResizableTextArea
- A text input area with handle icon in the bottom right corner that can be used to resize the typing input area.
- ZdsResponsiveTabBar
- A TabBar that solves certain issues with Material's TabBar. When using isScrollable is set to true in TabBar, the tabs will not fit the device's width. When isScrollable is set to false, the tabs all have the same size and do not change size to fit their children. This makes it awkward for certain situations where a non-scrollable tab bar is appropriate for certain big devices but not small ones, and where scrollable tab bars do not cover the entire width in big devices.
- ZdsSearchAppBar
- An AppBar with an integrated ZdsSearchField.
- ZdsSearchAppBarState
- State for ZdsSearchAppBar.
- ZdsSearchField
- A search field that can be used in a Form.
- ZdsSelectableListTile
- A list tile with circular edges that can be toggled between a selected and unselected state.
- ZdsSelectionPill
- A text button that can be selectable and that accepts a string and isButtonSelected boolean value.
- ZdsShakeAnimation
- The shake animation for the widgets.
- ZdsShakeAnimationState
- State for ZdsShakeAnimation, used to create a key:
- ZdsSheetHeader
- Creates the header component for a bottom sheet with Zds style.
- ZdsSlidableAction
- Defines an action that will be shown when sliding on a ZdsSlidableListTile.
- ZdsSlidableButton
- A SlidableButton with pre-applied Zds styling. This grows to the width of its container.
- ZdsSlidableButtonState
- State for ZdsSlidableButton.
- ZdsSlidableListTile
- A widget that creates a slidable list tile, which can be slid right-to-left to reveal further actions. Takes a child which can be any widget, although a Row is recommended to use like so:
- ZdsSlidableWidget
- A ZdsSlidableWidget with pre-applied Zds styling. This widget is used specifically in ZdsSlidableButton to create a SlidableButton.
- ZdsSlidableWidgetState
- State is required for the animation and updating the position on ZdsSlidableButton.
- A ZdsSplitNavigator used to navigate the screen for the split view for tablet.
- ZdsSplitNavigatorState is a state class for the ZdsSplitNavigator StatefulWidget. It extends the State class with NavigatorObserver and FrameCallbackMixin mixins.
-
ZdsSplitPageRouteBuilder<
T> -
A custom
PageRouteBuilder
class that creates a new route with a specified builder function. - ZdsStat
- A statistic definition to be used in ZdsStatCard.
- ZdsStatCard
- A card used to display value-key pairs.
- ZdsTab
- A Tab with Zebra styling.
- ZdsTabBar
- Returns a TabBar with Zds styling. However, this widget has a number of issues that make it less useful in varying screen sizes and resizable screens. It's recommended to instead use ZdsResponsiveTabBar.
- ZdsTabBarStyleContainer
- Applies style to any child of type ZdsTabBar.
- ZdsTabBarThemeData
- Theme container for ZdsTabBar.
- ZdsTag
- A tag used to show status information or selected options.
- ZdsTagsList
- Creates a list to show multiple ZdsTag.
- ZdsThemeData
- Class to allow custom color definitions in dark and light modes and used with new ZetaProvider
- ZdsThemeService
-
A class representing theme service which extends
ZetaThemeService
class. This class assists in loading and saving theme data. See also: - ZdsToast
- A container used with ZdsSnackBarExtension.showZdsToast to show a toast.
- ZdsToggleButton
- A large text button that can toggle between multiple values with Zds style.
- ZdsToggleButtonState
- State for ZdsToggleButton.
- ZdsToolbar
- A toolbar, used for additional actions that do not fit in the app bar.
- ZdsToolbarThemeData
- Theme data for ZdsToolbar.
-
ZdsValueController<
T> - Generic controller that can control a value that can be updated over time.
- A ZdsVerticalNav used to switch between different views. Should primarily be used for tablet views and larger screens.
- Zeta
- An InheritedWidget that provides access to Zeta theme settings.
- ZetaColorBase
- Default set of Zeta Colors that can be used to make a ZetaColors instance.
- ZetaColors
- Zeta Colors.
- ZetaColorScheme
- Easily craft stunning Flutter themes using pre-set color patterns or your own choices.
- ZetaColorSwatch
- A swatch of colors with values from 10 (light) to 100 (dark).
- ZetaGrid
- Zeta Grid.
- ZetaProvider
- A widget that provides Zeta theming and contrast data down the widget tree.
- ZetaProviderState
- The state associated with ZetaProvider.
- ZetaSpacing
- Zeta Spacing widget.
- ZetaSwatchGenerator
- Returns a map of colors shades with their respective indexes.
- ZetaText
- ZetaText component.
- ZetaThemeData
- A representation of the Zeta theme data.
- ZetaThemeService
-
ZetaThemeService
is an abstract class. It provides the structure for loading and saving themes in Zeta application.
Mixins
- FrameCallbackMixin
- This mixin could be used in the methods where you want to do some work after you are
Extensions
- AccessibilityIndices
- Extension on ZetaContrast to provide color indices for certain accessibility scenarios
- AppBarColor
- Extension method on ZetaAppBarStyle to add appBar color functionality.
- BorderModifiers
- Applies a decoration to the widget with a Border.
- BreakpointFull
- Utils to determine the DeviceType from the current context.
- BreakpointLocal
- Utils to determine the DeviceType from some box constraints.
- BuildContextRenderBox
- Render extensions on BuildContext.
- ColorModifers
- A selection of modifiers on Widget for colors
- DateTimeFormatter
- Extension on DateTime.
- DateTimeParser
- DateTime extension on String.
- DateTimeRangeUtils
- Extension on DateTimeRange.
- DefaultTextStylesModifiers
- Changes this widget's TextStyle.
- DeltaToHtml
- An extension on Delta to convert Delta content to HTML
- DeviceTypeFromContext
- Utils to determine the DeviceType from the current context.
- ExpandableTextExtension
- A widget extension that enables the widget to be collapsed and uncollapsed.
- HtmlToDelta
- An extension on String to convert HTML content to Quill's Delta format
- IconDataFromExt
- LaunchUrlInWebView
- Attempts to launch this urlString on a web view.
- LayoutModifiers
- A selection of modifiers on Widget for layouts
- LightHexColor
- Selection of extensions to Color.
- ListDivider
- Extension to add dividers to any view that can take an iterable.
- LoaderDialog
- Shows a dialog with a CircularProgressIndicator, used to indicate loading.
- MapExtensions
- This extension adds utility functions to the Map class.
- PaddingModifers
- A selection of modifiers on Widget for padding.
- PopOver
- Makes this widget a ZdsPopOverIconButton.
- RenderingModifiers
- A selection of modifiers on Widget for rendering
- RowLayout
- Center aligning row's children perfectly on the horizontal AND on the vertical axis
- SemanticsModifier
- Applies Semanctics to Widget
- SpacingSize
- Extension to get Spacing type as EdgeInsets from a double.
- SpacingWidget
- Extension to add spacing to any Widget.
- StatusBar
- Changes this Scaffold's SystemUiOverlayStyle.
- StringFormatter
- Formats the strings.
- TextMessage
- extension used to return different strings on exceptions.
- TextModifiers
- Changes this widget's TextStyle.
- TextThemeExtension
- A selection of modifiers on TextTheme.
- ThemeExtension
- Extension of ThemeData.
- ThemeModifiers
- Applies a Theme with custom ThemeData to the widget.
- XImage
- Created Image widget from XFile
- XSmall
- Extension to add Zeta's extra small text size.
- Zds
- Applies Zds styling to Widget
- ZdsSnackBarExtension
- Extension to show a ZdsToast
- ZdsXFile
- Constructors for XFile
- ZetaColorExtensions
- Extensions on Color to brighten, lighten, darken and blend colors and can get a shade for gradients.
- ZetaColorGetters
- Custom extension on ColorScheme which makes ZetaColors available through theme context.
- ZetaThemeBuilder
- A Dart extension on ZetaColorScheme
Constants
- calendarDaysOfWeekHeight → const double
-
Height of days of week in ZdsCalendar
36
- calendarRowHeight → const double
-
Height of row in ZdsCalendar
60
- checkableButtonSize → const double
-
Width / height of circular buttons in ZdsCheckableButton.
48
- kBigToggleHeight → const double
-
Height forZdsToggleButton.
40
- kBigTogglePadding → const double
-
Default padding for ZdsToggleButton.
18
- kBottomBarHeight → const double
-
Default bottom bar height.
62
- kDefaultBorderRadius → const double
-
Default border radius for ZdsTag.
6
- kDefaultHorizontalPadding → const double
-
Default horizontal padding for ZdsList.
14
- kDefaultVerticalPadding → const double
-
Default vertical padding for ZdsList.
8
- kHeaderBoarderSize → const double
-
Default header border size.
1
- kMaxActionHeight → const double
-
Default max action height.
48
- kMenuHorizontalPadding → const EdgeInsets
-
Default horizontal menu padding.
EdgeInsets.symmetric(horizontal: 24)
- kMenuVerticalPadding → const EdgeInsets
-
Default vertical menu padding.
EdgeInsets.symmetric(vertical: 24 / 2)
- kSearchBorderRadius → const double
-
Default radius for search bar.
53
- kSpace → const double
-
Space used for ZdsInputBorder.
6
- kToastHeight → const double
-
Default height of toast.
48
-
Width of ZdsVerticalNav
48
- kZdsCardElevation → const double
-
Default card elevation.
1
- kZdsCardMargin → const double
-
Default card margin.
3
- kZdsCardRadius → const double
-
Default radius for card.
8
- kZdsCardShadowColor → const Color
-
Shadow color used for cards
Color(0x33444D56)
- kZdsCheckableButtonSize → const double
-
Width / height of circular buttons in ZdsCheckableButton.
48
- kZdsListTileTheme → const ZdsListTileTheme
-
ListTile theme
ZdsListTileTheme(contentPadding: EdgeInsets.only(left: 24, top: 18, bottom: 18, right: 24), iconSize: 24, tileMargin: 6, labelAdditionalMargin: 10)
- kZdsSelectableListTileBorderRadius → const double
-
Border radius used for ZdsSelectableListTile.
30
- kZdsSelectableListTilePadding → const EdgeInsets
-
Padding used for ZdsSelectableListTile.
EdgeInsets.all(2)
- kZdsToolbarHeight → const double
-
Default toolbar height.
64
- kZdsToolbarTheme → const ZdsToolbarThemeData
-
Toolbar theme
ZdsToolbarThemeData(contentPadding: EdgeInsets.all(24))
- kZetaFontFamily → const String
-
Default font family for Zeta System
'packages/zeta_flutter/IBMPlexSans'
- kZetaSwatchPrimaryIndex → const int
-
Primary color shade index for ZetaColorSwatch
60
-
kZetaSwatchTargetContrasts
→ const Map<
int, double> -
Target contrast values for different color shades of ZetaColorSwatch
{100 : 17.42, 90 : 13.99, 80 : 8.33, 70 : 6.02, 60 : 4.57, 50 : 2.66, 40 : 1.83, 30 : 1.23, 20 : 1.09, 10 : 1.02}
- packageName → const String
-
Name of package
'zds_flutter'
- rectangularBorderRadius → const double
-
Rectangular border radius for ZdsTag.
2
-
zdsDefaultPostProcessors
→ const List<
ZdsFilePostProcessor> -
Default post processors
<ZdsFilePostProcessor>[ZdsFileCompressPostProcessor(), ZdsFileRenamePostProcessor()]
Functions
-
buildSheetBars(
{required BuildContext context, String primaryActionText = '', VoidCallback? primaryActionOnTap, String secondaryActionText = '', VoidCallback? secondaryActionOnTap, String ternaryActionText = '', VoidCallback? ternaryActionOnTap, String? title = '', bool showClose = false}) → List< Widget> - Method to build widgets for headerBuilder & bottomBuilder of showZdsBottomSheet This return an array of widgets which contains first element as ZdsSheetHeader and second element as ZdsBottomBar Here widgets gets computed based on the device(Mobile or Tablet).
-
buildZdsBottomBarThemeData(
BuildContext context) → ZdsBottomBarThemeData - Returns a ZdsBottomBarThemeData.
-
changeShade(
int rgb, double shade) → int -
Converts individual red, green, or blue of an input color to match a specific lightness shade
rgb
Red, green or blue color value of the initial colorshade
Shade from 0-1 -
clearUiTempDirectory(
) → Future< void> - Clears all files and cache from any ZdsFilePicker.
-
computeSystemOverlayStyle(
Color color) → SystemUiOverlayStyle - System overlay should be opposite to the brightness of the background color.
-
fileSizeWithUnit(
int bytes) → String - Converts byte length to human readable format.
-
firstSundayFromWeekInYear(
int weekNumber, int year) → DateTime - Gets the date of the sunday of a week in a year.
-
getAllowedFileBrowserTypes(
{required bool useLiveMediaOnly, required Set< String> allowedFileTypes}) → Set<String> -
it gives us a allowed file types
If
useLiveMediaOnly
is true then we remove all media (images & videos) types fromallowedFileTypes
set of strings IfuseLiveMediaOnly
is false then we returnallowedFileTypes
as it is. -
getDate(
DateTime d) → DateTime - To get Current week of start and end day.
-
getRandomColorFromTheme(
Object? seed, {List< Color> ? colors}) → Color - Returns a color from a set of chosen theme colors.
-
getShadedColor(
Color input, double shade) → Color -
Converts an input color into its shade with lightness
input
Color to be convertedshade
Shade from 0-1 -
hasIcons(
List< ZdsTab> items) → bool - Checks if the ZdsTab contains an icon
-
hasTextOverflow(
String text, TextStyle style, double width, {int maxLines = 1}) → bool -
Determines if
text
will overflow in a givenwidth
. -
iconColor(
String ext) → Color -
materialStatePropertyResolver<
T> ({T? hoveredValue, T? focusedValue, T? pressedValue, T? draggedValue, T? selectedValue, T? scrolledUnderValue, T? disabledValue, T? errorValue, T? defaultValue}) → MaterialStateProperty< T?> - Generates a MaterialStateProperty based on given values for different states.
-
numberOfWeeksInYear(
int year) → int - Gets the number of weeks in a year
-
rotateArrayLeft<
T> (List< T> array, int positions) → List<T> - rotate array to left by position
-
safeTextStyle(
TextStyle? style) → TextStyle - Method to return 'TextStyle'. This method will return a safe text style by providing a fallback to a default text style when no text style is provided.
-
showRflxDateRangePicker(
{required DateTime firstDate, required DateTime lastDate, required BuildContext context, DateTimeRange? initialDateRange, DateTime? currentDate, DatePickerEntryMode initialEntryMode = DatePickerEntryMode.calendar, String? helpText, String? cancelText, String? confirmText, String? saveText, String? errorFormatText, String? errorInvalidText, String? errorInvalidRangeText, String? fieldStartHintText, String? fieldEndHintText, String? fieldStartLabelText, String? fieldEndLabelText, String? clearButtonString, String? applyButtonString, Locale? locale, RouteSettings? routeSettings, TextDirection? textDirection, TransitionBuilder? builder, List< Widget> ? actions, bool isWeekMode = false, int startingDayOfWeek = 0}) → Future<DateTimeRange?> - Use showZdsDateRangePicker
-
showZdsBottomSheet<
T> ({required BuildContext context, required WidgetBuilder builder, Color? backgroundColor, Color? barrierColor = Colors.black54, double? maxHeight, double? maxWidth, double? bottomInset, bool isDismissible = true, bool enableDrag = true, bool enforceSheet = false, EdgeInsetsGeometry? contentPadding, PreferredSizeWidget headerBuilder(BuildContext)?, PreferredSizeWidget? bottomBuilder(BuildContext)?}) → Future< T?> - Shows a bottom sheet with Zds styling.
-
showZdsDateRangePicker(
{required DateTime firstDate, required DateTime lastDate, required BuildContext context, DateTimeRange? initialDateRange, DateTime? currentDate, DatePickerEntryMode initialEntryMode = DatePickerEntryMode.calendar, String? helpText, String? cancelText, String? confirmText, String? saveText, String? errorFormatText, String? errorInvalidText, String? errorInvalidRangeText, String? fieldStartHintText, String? fieldEndHintText, String? fieldStartLabelText, String? fieldEndLabelText, String? clearButtonString, String? applyButtonString, Locale? locale, RouteSettings? routeSettings, TextDirection? textDirection, TransitionBuilder? builder, List< Widget> ? actions, bool isWeekMode = false, int startingDayOfWeek = 0, String? shortMonthDayFormat, String? shortDateFormat}) → Future<DateTimeRange?> - Shows a full screen modal dialog containing a Material Design date range picker.
-
showZdsPopOver<
T> ({required BuildContext context, required WidgetBuilder builder, Color? backgroundColor, double radius = 6, double contentDyOffset = 0.0, Duration transitionDuration = const Duration(milliseconds: 100), BoxConstraints? constraints, VoidCallback? onPop, String? barrierLabel}) → Future< T?> - Future that creates a popover.
-
startingDayOfWeekToInt(
StartingDayOfWeek startingDayOfWeek) → int - Returns an int representing the starting day of week.
-
startMonthDay(
DateTime date, {int startingDayOfWeek = 1}) → DateTime - Gets the first day of the first week of a month. Commonly this is not the first of the month, unless that happens to fall on the start day of the week.
-
textWidth(
String text, TextStyle style, {int maxLines = 1}) → double -
Gets the width of a
text
with a givenstyle
. -
zdsFileError(
BuildContext context, FilePickerConfig config, Exception exception) → void - Default error handler
-
zdsValidator(
ZdsFilePickerController controller, FilePickerConfig config, FileWrapper wrapper, FilePickerOptions option) → Future< FilePickerException?> - Default file validator
Enums
- DateTimePickerMode
- Variants of ZdsDateTimePicker.
- DeviceType
- Enum to define device types.
- ExpansionTileType
- Types of expansion tile
- FilePickerOptions
- Extension on FilePickerException to show message Types of files the ZdsFilePicker can be used to pick.
- MediaType
- An enumeration to represent different types of media content.
- PickerExceptionType
- Types of errors, commonly used to generate error toast messages later
- QuillToolbarOption
- toolbar options
- QuillToolbarPosition
- enum for toolbar position
- ZdsButtonVariant
- Variants of ZdsButton.
- ZdsCardDirection
- The direction in which a ZdsCardWithActions.children will be laid out.
- ZdsCardVariant
- Variants of ZdsCard.
- ZdsFilePickerDisplayStyle
- Whether to display the ZdsFilePicker as a horizontal row or vertical column.
- ZdsInformationBarTheme
- Sets a ZdsInformationBar's icon and background colors.
- ZdsOptionDisplay
- UI Variants of the ZdsFilePicker.
- ZdsPropertiesListDirection
- Enum to determine direction used in ZdsPropertiesList.
- ZdsSearchFieldVariant
- Variants of ZdsSearchField.
- ZdsTabBarColor
- Theme colors for ZdsTabBar.
- ZdsTagColor
- Tag colors
- ZdsToastColors
- Determines foreground and background color of toast to comply with design rules.
- ZetaAppBarStyle
- Enum to select the used AppBarTheme style in ZetaColorScheme based themes.
- ZetaContrast
- ZetaAccessibilityStandard is an enumeration that defines the Web Content Accessibility Guidelines (WCAG) 2.1. It includes two levels of conformance: AA (minimum) and AAA (enhanced).
- ZetaSpacingType
- Spacing types for ZetaSpacing.
Typedefs
- BuildContextProvider = BuildContext Function()
- Context used for page navigation
- BuilderCallback = Widget Function(BuildContext context, int index)
- Callback function for ZdsHorizontalList.builder method.
- DateRange = ZdsDateRange
- A date range selector that also allows to quickly change the range selected by jumping to the next or previous set of dates.
-
GiphyGetWrapperBuilder
= Widget Function(Stream<
GiphyGif> , GiphyGetWrapper) - SearchAppBarBuilder = Widget Function(BuildContext context, FocusNode focusNode, bool autofocus, TextEditingController textEditingController, void onClearSearch())
- SlidableActionCallback = void Function(BuildContext context)
- Signature for CustomSlidableAction.onPressed.
- TabBottomBuilder = Widget Function(BuildContext context)
- TabTopBuilder = Widget Function(BuildContext context)
-
ZdsFileValidator
= Future<
FilePickerException?> Function(ZdsFilePickerController controller, FilePickerConfig config, FileWrapper fileWrapper, FilePickerOptions option) - File validator
- ZetaAppBuilder = Widget Function(BuildContext context, ZetaThemeData themeData, ThemeMode themeMode)
- A typedef for the ZetaAppBuilder function which takes BuildContext, ZetaThemeData, and ThemeMode and returns a Widget.
Exceptions / Errors
- FilePickerException
- Class defining different exceptions types with its arguments