widgets library

Cards, clips, carousel, decoration, display, glass, and rating widgets.

Classes

AnimatedGestureDetector
Wraps child with a short press animation before calling onTap.
UIAnimatedCounter
Animated numeric display with optional grouping and decimal digits.
UIAnimatedCounterController
Controller for UIAnimatedCounter.
UIAnimatedFlipCard
Interactive card that flips between a front and back face.
UIAnimatedFlipCardStyle
Visual configuration for UIAnimatedFlipCard.
UIAnimationConfiguration
Provides animation config (position, duration, delay, column count) to descendant UIAnimationConfigurator widgets via InheritedWidget.
UIAnimationConfigurator
Reads UIAnimationConfiguration from context and drives a controller.
UIAnimationLimiter
Limits stagger animations to only the first build frame.
UIAppBarProps
Forwarded AppBar parameters for kit app bar wrappers.
UIAvatarGlow
Pulsing glow effect around child, useful for live status indicators.
UIBatteryIndicator
Custom-painted battery level indicator.
UIBatteryIndicatorPainter
Custom painter that draws the battery body, fill level, and optional percent label.
UICard
A styled card widget that provides consistent elevation and corner radius.
UICardProps
Forwarded Card parameters for kit card wrappers.
UICardTopContainer
Header row for UICard with title, optional "view all" action, and icon.
UICarouselControls
Prev/next buttons and page indicators for carousels.
UICarouselControlsColors
Color tokens for UICarouselControls navigation and indicators.
UICarouselNavButton
Circular prev/next control for UICarouselControls.
UICarouselPageIndicators
Dot indicators showing the active page in a carousel.
UICarouselRowPage<T>
Lays out a horizontal row of carousel items with optional trailing spacer.
UICarouselWithIndicator
Paging carousel with animated dot indicators.
UICircleProgressPainter
Circular progress arc painter for custom gauge and ring indicators.
UICommandBar
Horizontal toolbar with dynamic overflow into a "more" menu.
UICommandBarItem
One action displayed in UICommandBar.
UICornerRibbon
Diagonal corner ribbon overlay (e.g. "SALE", "NEW") on top of child.
UICouponCard
Split-panel coupon card with curved tear lines between firstChild and secondChild.
UICouponClip
Clips child to a split-panel coupon shape with curved tear lines.
UICouponClipper
Clips a widget to a split-panel coupon shape with curved tear lines.
UICouponDecorationPainter
Paints shadow and border along a coupon clip path for UICouponCard.
UICurrentReadingRow
A row displaying a current reading with an icon and a value.
UIDetailInfoBanner
Centered info banner for detail screens.
UIDialogProps
Forwarded Dialog parameters for kit dialog wrappers.
UIDottedBorder
Draws a dotted rounded-rect border around child.
UIExpansionAccord
An accordion that expands one or more UIExpansionAccordItems.
UIExpansionAccordItem
A single expandable section inside UIExpansionAccord.
UIExpansionTile
Expandable tile with header, trailing icon, and collapsible body content.
UIExpansionTileStyle
Visual styling for UIExpansionTile and UIExpansionAccordItem.
UIFadeInAnimation
Fades a child from transparent to opaque.
UIFlipAnimation
Flips a child in 3D along the X or Y axis.
UIGlassCard
Frosted-glass card with optional tap handling.
UIGlassConstants
Default blur, opacity, and radius values for glass widgets.
UIGlassScaffold
Scaffold with a gradient background and optional glass chrome wrappers.
UIGlassSurface
Frosted-glass surface using BackdropFilter (no extra dependencies).
UIGlassTheme
Shared visual tokens for UIGlassSurface and other glass widgets.
UIGradientBox
A container that supports gradient backgrounds and borders.
UIGradientSvgIcon
An SVG icon that renders with a gradient fill.
UIGradientText
A text widget that renders with a gradient fill.
UIHexagon
A widget clipped to a hexagonal shape.
UIHexagonClipper
Custom clipper that shapes widgets into a flat-top hexagon.
UIIconBadge
A circular or rounded container for an icon with an accent background.
UIIconTextColumn
Vertically stacked icon with primary and secondary text labels.
UILabeledDataTable
A simple data table with labeled columns and rows.
UIListTileProps
Forwarded ListTile parameters for kit list wrappers.
UIListTileSelect
Selectable list tile with title, subtitle, and selection highlight.
UIMarquee
Continuously scrolls overflowing child content horizontally or vertically.
UIMetricListTile
List tile with icon badge, title, value line, and optional trailing text.
UIPrimaryActionBar
Full-width accent action button pinned to the bottom of a screen or sheet.
UIProgressBar
Linear progress indicator with determinate and indeterminate modes.
UIRatingBar
Interactive star (or custom) rating bar with optional half-star support.
UIRatingBarIndicator
Read-only rating display that supports fractional values.
UIRatingWidget
Full, half, and empty widgets used by the rating bar widgets.
UIReadMoreAnnotation
Highlighted pattern inside UIReadMoreText (URLs, mentions, etc.).
UIReadMoreText
Expandable text with optional pattern annotations and line/length trimming.
UIRichText
A text widget that supports multiple styles and interactive segments.
UIRichTextSpan
Configuration for a segment of text within a UIRichText widget.
UIScaleInAnimation
Scales a child from scale to 1.0.
UISectionCarousel
Horizontal paging carousel with prev/next controls and pill-dot indicators.
UISectionHeader
A standard section header with an optional icon and title.
UISegmentedBar
Segmented horizontal bar for proportional data (e.g. sleep stages).
UISegmentValue
One proportional segment in a UISegmentedBar.
UISemanticsProps
Reusable accessibility parameters shared across kit widgets.
UISettingsSectionCard
Rounded card grouping settings rows with consistent padding.
UISharpCorners
Clips child with diagonal cuts on selected corners.
UISharpCornersClipper
Custom clipper for UISharpCorners.
UISlideInAnimation
Slides a child from an offset to its natural position.
UIStackBadge
Overlays a small label badge on child in a Stack.
UIStatSummaryCard
A card that displays a row of statistics.
UIStatSummaryItem
Represents a single statistic item with a label and a value.
UIStatusBanner
Card-style status row with a leading widget, title, subtitle, and optional tap.
UISummaryGrid
Two-column (by default) grid of icon + label + value cards.
UISummaryGridItem
Single cell in a UISummaryGrid with icon, label, and value.
UISwipeAction
One swipe-revealed action behind UISwipeActionTile.
UISwipeActionTile
List tile that reveals trailing actions when swiped left.
UITapGuard
Prevents duplicate taps while an async onTap is running.
UIText
A standard text widget with easy access to common styling properties.
UITextAvatar
Circular avatar showing initials derived from name.
UITextRow
Horizontal row with optional prefix, primary text, and suffix widgets.
UITicketClip
Clips child to a ticket/coupon shape with optional edge notches.
UITicketClipper
Custom clipper for UITicketClip.
UITimerBuilder
Rebuilds its child on a periodic or scheduled timer.

Enums

BatteryIndicatorStyle
Visual style for UIBatteryIndicator.
SegmentOrder
Sort order applied when painting UISegmentedBar segments.
TapEffect
Preset tap feedback styles for AnimatedGestureDetector.
UICornerRibbonLocation
Corner placement for UICornerRibbon.
UIFlipAxis
Axis for UIFlipAnimation.
UIFlipDirection
Axis used by UIAnimatedFlipCard for the 3D flip animation.
UIMarqueeMode
Scroll behavior for UIMarquee.
UIReadMoreTrimMode
How UIReadMoreText trims overflowing content.
UISharpCorner
Which corners receive a diagonal cut in UISharpCorners.
UIStackBadgePosition
Corner placement for UIStackBadge.
UITicketNotchSide
Side along which ticket notches are cut.

Constants

kUITextAvatarLetterColors → const Map<String, Color>
Default letter-to-color map for UITextAvatar backgrounds.

Functions

buildUILabel(String text, {Widget? child, double? size, Color? color, FontWeight? fontWeight, TextStyle? style, int? maxLines, TextAlign? textAlign, TextOverflow? textOverflow, double? lineHeight, double? letterSpacing}) Widget
Shared text and layout helpers used across form fields, dropdowns, and rich-text widgets in this package.
carouselCardWidth(double width, {required int itemsPerPage, double gap = 12, double pagePadding = 4, double cardPadding = 32}) double
carouselPageCount(int itemCount, int itemsPerPage) int
carouselPageSlice<T>(List<T> items, int pageIndex, int itemsPerPage) List<T>
createUITimerStream(UITimerGenerator generator, Future<void> stopSignal) Stream<DateTime>
defaultUIRatingWidget(BuildContext context, {double size = 24, Color? filledColor, Color? emptyColor}) UIRatingWidget
Builds a default star UIRatingWidget using theme-aware colors.
getBoxConstraintsLoose(BuildContext context) BoxConstraints
Returns loose constraints sized to roughly half the screen width.
getMaxLines(String text, TextStyle style, double maxWidth) int
Calculates the number of lines required to display text with style within maxWidth.
getTextHeight(BuildContext context, String text, TextStyle style, double maxWidth, int? maxLines, {TextDirection? direction, double bufferSpacing = 5}) double
Calculates the height required to display text within given constraints.
intersperse(List<Widget> widgets, Widget divider, {bool leading = false, bool trailing = false}) List<Widget>
Inserts divider between each widget in widgets.
itemsPerPageForWidth(double width, {int mobile = 1, int tablet = 2, int desktop = 2}) int
textSpan(String text, Color color, FontWeight fontWeight, double fontSize, {TextStyle? base, VoidCallback? onTap, TextDecoration? decoration}) TextSpan
Creates a TextSpan with optional tap handling.
textStyle({required Color color, required FontWeight fontWeight, required double fontSize, TextStyle? base, TextDecoration? decoration, Color? decorationColor, double? decorationThickness}) TextStyle
Creates a TextStyle with common parameters, merging onto an optional base.
uiAlignDateTime(DateTime dateTime, Duration alignment, [bool roundUp = false]) DateTime
uiFromDateTimeIterable(Iterable<DateTime> iterable) UITimerGenerator
uiGetAlignmentUnit(Duration interval) Duration
uiPeriodicTimer(Duration interval, {Duration alignment = Duration.zero}) UITimerGenerator
uiScheduledTimer(Iterable<DateTime> schedule) UITimerGenerator
widgetMap<T>(List<T> widgets, List<Widget> mapFunc(T)) List<Widget>
Maps each item in widgets through mapFunc and flattens the result.

Typedefs

UIAccordionItemStyle = UIExpansionTileStyle
Accordion-style configuration used by UIExpansionAccordItem.
UITimerGenerator = DateTime? Function(DateTime now)
Returns the next rebuild time for UITimerBuilder.