components library
Only the kit components, without AppTheme or AppColors.
Use this import to keep the app's Material theme. Widgets fall back to the kit's palette and style until you provide a LumenScope or register a LumenThemeExt.
import 'package:lumen_kit/components.dart';
Classes
- LumenActionContent
- Default action content: spinner (when busy) or icon, followed by the label.
- LumenAnimatedGridBackground
- Decorative backdrop with futuristic grid, gradient and glow orbs.
- LumenAppBar
- AppBar with neon identity: transparent, with bottom gradient line and typography consistent with the theme.
- LumenAvatar
- Circular avatar with gradient border and optional glow.
- LumenAvatarGroup
- Stacked avatars with overlay and a "+N" for overflow.
- LumenBadge
- Displays a small label or dot as a standalone badge or over child.
- LumenBanner
- Displays a persistent inline alert with optional action and close buttons.
- Bottom navigation bar with a themed highlight on the selected item.
- LumenButton
-
Neon button with three variants: LumenButtonVariant.solid,
LumenButtonVariant.outline and LumenButtonVariant.ghost.
For primary CTA with full gradient, prefer LumenButtonVariant.solid (or
the historical shortcut
LumenCta). - LumenCard
- Neon theme base container: subtle gradient + accent border + optional onTap.
- LumenCarousel
-
PageViewwith rounded cards, the current page highlighted and a LumenPageIndicator below. - LumenCheckbox
- Square checkbox with accent border and gradient marker when active.
- LumenChip
- Displays a chip with selection controlled by the caller.
-
LumenChipItem<
T> - Option of LumenChoiceChips and LumenFilterChips.
-
LumenChoiceChips<
T> - Group of single-choice chips (e.g.
- LumenCircularProgress
- Circular spinner with neon gradient.
-
LumenContextMenu<
T> - Opens a context menu at the pointer position on right-click or long press.
- LumenCta
- Primary CTA with neon gradient.
- LumenDataTable
-
A horizontally scrollable
DataTablestyled with the active Lumen theme. - LumenDatePicker
- Displays a date in a read-only field that opens showLumenDatePicker.
- LumenDecorations
- Decorations shared by kit widgets.
- LumenDialog
- Stylized dialog with gradient surface, accent border and theme typography.
- LumenDivider
- Draws a themed horizontal or vertical divider.
- LumenDrawer
-
Side drawer with gradient background and vertical accent border.
Use directly on
Scaffold(drawer: LumenDrawer(...)). Children can be any widgets — usually a custom header followed by LumenDrawerItems. - LumenDrawerItem
- Item defaults to LumenDrawer, with glow in the selected state.
-
LumenDropdown<
T> - Stylized dropdown with theme border and glow.
-
LumenDropdownItem<
T> - Item displayed on LumenDropdown.
- LumenEmptyState
- Displays an empty state with a title, optional message, icon, and action.
- LumenExpansionTile
- Expandable tile with surface header, icon with animated rotation and border accent when opened.
- LumenFab
- Themed floating action button with compact and extended layouts.
-
LumenFilterChips<
T> - Group of filter chips (several marked at the same time, with check).
- LumenGlowOrbSpec
- Configuration of a glow orb positioned in the background.
- LumenIconButton
- Circular/square button containing just one icon, in neon style.
- LumenLabeled
- Control followed by a text label, with the color turned off when disabled.
- LumenLinearProgress
-
Linear progress bar with neon and glow gradient.
If value is
null, displays indeterminate animation. - LumenList
- A scrollable list that builds items on demand.
- LumenListTile
- Themed ListTile with translucent surface, soft accent border and state selected highlighted by glow.
- LumenLoadingOverlay
-
Covers child with a layer that blocks touch, focus and screen reader while
loading is
true, with spinner and message in the center. To lock the entire screen during an operation (e.g. submit), without save loading state, use showLumenLoading. - LumenLoadingPanel
- Panel with spinner and message used by LumenLoadingOverlay and showLumenLoading.
-
LumenMenuButton<
T> - "⋮" button (or another icon) that opens an action menu anchored to it.
-
LumenMenuDivider<
T> - Line separating groups of actions.
-
LumenMenuEntry<
T> - Entering a neon menu: LumenMenuItem or LumenMenuDivider.
-
LumenMenuItem<
T> - Action of a neon menu.
- LumenMotion
- Motion helpers that respect the system's "reduce animations".
- Reusable main screen navigation card.
- Item from LumenBottomNavBar / LumenNavRail.
- Side variant (tablet/desktop).
- LumenPageIndicator
- Page dots for onboarding and galleries.
- LumenPalette
- Color tokens for a Lumen theme.
- LumenPinField
- A one-time code field controlled by value.
- LumenPressable
- Touchable Kit Base: Applies Disabled Opacity, Cropped Ripple in borderRadius, keyboard focus and button semantics. Use to build your own components with the same behavior as kit buttons:
- LumenQuantityStepper
- Numeric input "− 1 +" for cart and settings.
-
LumenRadio<
T> - Circular radio with glow in the selected state.
- LumenRangeSlider
- Interval slider (two thumbs) with the same look as LumenSlider.
- LumenRating
- Rating stars.
- LumenScope
- Overrides the Lumen palette and style for a widget subtree.
- LumenSearchBar
- Compact search bar, with magnifying glass prefix and clear button when there is content.
- LumenSegmentedControl
- Segmented control compact (pill).
- LumenSkeleton
- Displays a placeholder with a shimmer while content loads.
- LumenSlider
- Slider with a solid accent track and a thumb that follows the shadow style.
- LumenStatusChip
- Compact chip that communicates status by color semantics.
- LumenStep
- Definition of each step.
- LumenStepper
- Themed step progress indicator for horizontal or vertical layouts.
- LumenStyle
- Kit visual effect tokens: shadow, fill, surface, border and background.
- LumenSwitch
- Stylized switch with translucent track, thumb accent and glow when active.
- LumenTabItem
- Item from LumenTabs / LumenSegmentedControl.
- LumenTableRow
-
"By hand" line for those who want to compose a light table without
DataTable(ex: inside cards). - LumenTabs
- Horizontal tabs with a solid accent underline.
- LumenTag
-
Compact tag — lightweight variation of
LumenStatusChip, with no required icon and no strong glow. - LumenTextField
- Neon text field.
- LumenThemeExt
-
Stores the Lumen palette and style in
ThemeData. - LumenTimePicker
- Read-only field that opens showLumenTimePicker when touched.
- LumenTooltip
- Stylized tooltip following the neon identity (translucent surface, accent + glow).
Enums
- LumenBackgroundKind
- LumenAnimatedGridBackground decoration.
- LumenButtonVariant
- Visual variants of LumenButton.
- LumenIconButtonShape
- LumenIconButton format.
- LumenIconButtonVariant
- Visual variants of LumenIconButton.
- LumenPreset
- Ready-made palettes.
- LumenShadowKind
- How widget shadows are drawn.
- LumenStatusTone
- Semantic tone for a status chip.
- LumenStepperDirection
- LumenStepper presentation direction.
- LumenToastPosition
- Vertical position of the toast on the screen.
Extensions
- LumenOutlineColor on Color
- Adjusts opacity for Lumen palette colors.
- LumenStatusToneColor on LumenStatusTone
- Resolves the color of a LumenStatusTone from the active palette.
Constants
- kLumenDisabledOpacity → const double
- Default opacity for controls that use Lumen's disabled dimming effect.
- kLumenFastDuration → const Duration
- Duration of short transitions (hover, selection, toggle).
- kLumenMediumDuration → const Duration
- Duration of average transitions (expand, swap content).
Functions
-
lumenMenuPositionAt(
BuildContext context, Offset globalPosition) → RelativeRect -
Position for showLumenMenu at a global point on the screen (e.g.:
TapUpDetails.globalPositionfrom a right click). -
neonMenuPositionAt(
BuildContext context, Offset globalPosition) → RelativeRect - Old name of lumenMenuPositionAt.
-
showLumenBottomSheet<
T> ({required BuildContext context, required WidgetBuilder builder, Color? accentColor, bool isScrollControlled = true, bool isDismissible = true, bool enableDrag = true}) → Future< T?> - Opens a themed modal bottom sheet and returns its result.
-
showLumenDatePicker(
{required BuildContext context, required DateTime initialDate, required DateTime firstDate, required DateTime lastDate, Color? accentColor, String? helpText}) → Future< DateTime?> - Opens the Material date picker with colors from the active Lumen palette.
-
showLumenDialog<
T> ({required BuildContext context, required String title, required Widget content, List< Widget> actions = const <Widget>[], Color? accent, IconData? icon, bool barrierDismissible = true}) → Future<T?> -
Displays a LumenDialog and returns the result of
showDialog. -
showLumenLoading<
T> ({required BuildContext context, required Future< T> task(), String? message, Color? accentColor, Color? barrierColor}) → Future<T> -
Blocks the screen with a LumenLoadingPanel while
taskruns. -
showLumenMenu<
T> ({required BuildContext context, required List< LumenMenuEntry< items, RelativeRect? position, Color? accentColor, T? initialValue}) → Future<T> >T?> -
Opens a floating menu with
itemsand returns the chosen value, ornullif the menu is closed without a choice. Withoutposition, the menu opens anchored just below the widget owner ofcontext(like the "⋮" on a card). To open at a point on the screen (e.g.: right click), use lumenMenuPositionAt. -
showLumenSnackBar(
{required BuildContext context, required String message, LumenSnackTone tone = LumenStatusTone.info, IconData? icon, Duration duration = const Duration(seconds: 4), SnackBarAction? action}) → ScaffoldFeatureController< SnackBar, SnackBarClosedReason> -
Displays a styled snackbar on the nearest
ScaffoldMessenger. Reuses theSnackBarfrom the Material but exchanges the content for a surface with accent + glow border, in the style of the rest of the kit.tonesets the default color and icon, anddurationcontrols display time. The button built fromactionuses its label and callback. Pressing it dismisses the snackbar withSnackBarClosedReason.actionbefore invoking the callback. -
showLumenTimePicker(
{required BuildContext context, required TimeOfDay initialTime, Color? accentColor, String? helpText, bool? use24HourFormat, TimePickerEntryMode initialEntryMode = TimePickerEntryMode.dial}) → Future< TimeOfDay?> - Opens the Material time picker with Lumen colors and corner radii.
-
showLumenToast(
{required BuildContext context, required String message, LumenStatusTone tone = LumenStatusTone.info, IconData? icon, Duration duration = const Duration(seconds: 3), LumenToastPosition position = LumenToastPosition.bottom, double margin = 24}) → Future< void> -
Displays a floating toast over the app via
Overlay, without depending onScaffoldMessenger.
Typedefs
- AnimatedGridBackground = LumenAnimatedGridBackground
- Old name of LumenAnimatedGridBackground.
- GlowOrbSpec = LumenGlowOrbSpec
- Old name of LumenGlowOrbSpec.
- LumenSnackTone = LumenStatusTone
- Snackbar semantic tone — uses the same colors as LumenStatusTone.