stunning_ui 2.0.0
stunning_ui: ^2.0.0 copied to clipboard
A production-ready, highly interactive, and glassmorphic UI toolkit for Flutter.
2.0.0 #
- The auto-palette engine — one colour in, a full design system out. New
StunningPalette.fromSeed(primary, {secondary, harmony, brightness})derives a complete, harmonious, WCAG-AA colour system entirely in HCT space:- Harmony auto-pick — pass only a primary and the engine chooses the right
relationship from the seed's chroma (vibrant → complementary, calm →
analogous, near-grey → monochromatic). Or pick one explicitly via
StunningHarmony(triadic / splitComplementary / …). A suppliedsecondaryColoris auto-harmonised onto the primary so it never clashes. - Tailwind 50→950 tonal ramps per role via
palette.ramp(StunningRole.x)— perceptually even by construction (tone == luminance). - Brand-tuned semantics —
palette.semantics.success/warning/error/info, each hue-shifted a bounded amount toward the brand (error stays unmistakably red, success green), each with an AA-guaranteedoncolour, a container, and its own ramp. - Mathematical contrast guarantee —
palette.on(anyBackground, {ratio})returns a brand-tinted foreground that always meets WCAG AA (or AAA), andpalette.contrastReport()proves it (printed by:doctor). - Auto-derived gradients (
palette.gradients.primary/brand/mesh), glass tint and a luminous glow colour (now poweringStunningTheme.glowingShadow).
- Harmony auto-pick — pass only a primary and the engine chooses the right
relationship from the seed's chroma (vibrant → complementary, calm →
analogous, near-grey → monochromatic). Or pick one explicitly via
StunningTheme.generategains optionalsecondaryColor+harmonyand exposes the system viaStunningTheme.palette/.semantics. The harmonised secondary/tertiary and brand error are injected into the Material 3 scheme.- Theme share-codes —
theme.toShareCode()/StunningTheme.fromShareCode()pack a whole theme into a short versioned string (e.g.st1_3qNkk). StunningAnimatedThememorphs the whole app between themes/styles (every token interpolates), andStunningAccent(seedColor:)recolours a subtree from one colour for multi-brand UIs.- Backward compatible: existing single-seed
generate()calls are unchanged — the palette is additive.material_color_utilitiesis promoted to a direct dependency (already ships transitively with Flutter, so no new package in users' lockfiles). - Breaking (semver 2.0): the Material
ColorSchemeis now palette-driven, so apps may see a small, intentional shift toward brand-tuned neutrals and harmonised accents.
1.8.0 #
- Developer tooling (DX):
- CLI —
dart run stunning_ui:doctor(verifies your setup: Flutter version, theme wiring, hardcoded colours) anddart run stunning_ui:init(scaffolds a starter theme). registry.json+llms.txt— a machine-readable catalogue of every component (generated bytool/build_registry.dart, guarded by a drift test) so AI agents and tooling have an accurate source of truth.- GitHub Actions CI (
format+analyze+test) anddartdoc_options.yaml(API docs link to source). - A Widgetbook gallery (
example/lib/widgetbook.dart) to browse all components across the enterprise / minimal / gaming themes.
- CLI —
- The entire codebase is now
dart formatclean.
1.7.0 #
- Slot-based
StunningButton: now accepts anicon, a customchild, asize(small/medium/large), and addstonal+dangervariants — fully backward compatible (textstill works). - 12 new components, all accessible (semantics + keyboard + 48dp), theme-driven (light + dark) and reduce-motion aware:
- Inputs:
StunningCheckbox,StunningRadio<T>,StunningSlider, and a generic overlayStunningSelect<T>. - Feedback/overlays:
StunningDialog(+.confirm/.success/.errorpresets and ashowStunningDialoghelper),StunningProgressBar,StunningProgressRing,StunningTooltip. - Display:
StunningBadge,StunningAvatar,StunningDivider. - Navigation:
StunningPagination.
- Inputs:
StunningTiltCardrebuilt onGlassSurfaceand now tilts on touch (pan) as well as hover — springing back on release and collapsing to flat under reduce-motion (previously it only responded to mouse hover).- Test suite expanded to 31 tests (accessibility, motion, glass, button, forms, overlays, select/nav, card).
1.6.0 #
- Production glass —
GlassSurface+.glass(): the single glass recipe for the kit. Real index-of-refraction lensing on Impeller (viaImageFilter.shader), automatic blur fallback on Skia/web, and a solid opaque surface under reduce-transparency — all tinted and sized from the theme. Use the widget directly or via the chain:widget.stunning().glass(). StunningGlassScope: coalesces every descendant glass surface into a single backdrop blur pass (BackdropGroup) for performance.StunningUI.warmUp(): precompiles the refraction shader so the first glass surface never pops.StunningEffectTier(full / reduced / off) to gate effect cost.- BREAKING (toolchain): the minimum Flutter version is now 3.41 (was 3.29) — required for
ImageFilter.shaderglass refraction andBackdropGroupblur coalescing. - Added
test/glass_test.dart.
1.5.0 #
- Motion engine + chainable
.stunning()API — apply spring-physics effects to any widget:widget.stunning().glow().tilt().springIn().springIn()— spring-physics entrance (fade + scale + optional slide) that settles exactly viaSpringSimulation(snapToEnd: true).glow()— themed brand glow with an optional breathingpulse.tilt()— interactive 3D tilt that follows the pointer and springs back on exit.List<Widget>.stunningStagger()— staggered spring entrance for columns/lists.
- Theme spring token:
StunningSpring.toSpring()converts the style's duration + bounce into a physicsSpringDescription(enterprise = snappy, gaming = bouncy). - All motion honors reduce-motion (collapses to instant). Added
test/motion_test.dart.
1.4.0 #
- Accessibility by default: a new
StunningTappableprimitive powers every interactive component — screen-reader roles (button / toggle / selected), full keyboard support (Tab to focus, Enter/Space to activate), a focus-visible ring, and a 48dp minimum tap target. Buttons, switches, tabs, segmented controls, accordions, bottom-nav, sidebar and dropdown items are now keyboard- and screen-reader-operable (previously the kit had zeroSemantics). - Reduce-motion: all animated components honor the OS "reduce motion" setting via
StunningTheme.of(context).motion(context)(durations collapse to zero); looping effects like shimmer fall back to a static state. - New accessibility helpers on
StunningTheme:motion(context),blurFor(context), and staticreduceMotion(context)/reduceTransparency(context). - Added a package
test/suite with accessibility guideline tests (tap-target size, labeling, and semantics).
1.3.0 #
- Theme Engine v2:
StunningTheme.generate()now derives a full Material 3ColorSchemefrom the seed colour (style-awareDynamicSchemeVariant), alongside the existing glass/glow/border/motion tokens. - One-line setup: new
StunningTheme.light(),.dark(),.gaming(),.enterprise(), and.minimal()presets plus atoThemeData()helper. - Light mode fixed: every component now resolves text/icon/border/hint colours from the theme (via the new non-null
StunningTheme.of(context)and brightness-aware getters liketextPrimary/hintColor/borderColor) instead of hardcodedColors.white— the kit now renders correctly in both light and dark. - Theme-driven glass: components that hardcoded a blur sigma now read
glassBlurSigma, so theenterprisestyle is truly flat (no blur, no wasted GPU). - Motion tokens: added
StunningSpring(duration + bounce) derived from the active style; smoothedThemeExtension.lerpduration interpolation. - Fix: removed the public top-level
lerpDoublethat shadoweddart:ui's and could cause an ambiguous-import error in consumers;dart:ui's is now used internally.
1.2.0 #
- New Components: Added
StunningModal,StunningDropdown,StunningToast,StunningSkeleton,StunningSwitch,StunningTabs, andStunningBarChart. - Enterprise Ready: Optimized the framework for Dark SaaS and dense data dashboards.
- Bug Fixes: Resolved RenderFlex overflow bugs in animated switches and fixed Glass Bleed readability issues in transparent toasts.
- UX Improvements: Upgraded physics-based animations (bouncy curves and scale transitions) for all interactive inputs.
1.1.0 #
- Adaptive Theme Engine: Introduced
StunningThemeandStunningUIStyle(Enterprise, Minimal, Gaming) for global styling. - Components: Added
StunningDataTablewith smart status badge detection and floating/solid layout options.
1.0.3 #
- Added
topOffsetandbottomOffsettoStunningToastfor precise positioning. - Added
backgroundColor,margin, andindicatorWidthcustomization toStunningBottomNav. - Introduced dynamic colors and
StunningButtonVariant(primary, outline, ghost) forStunningButton.
1.0.2 #
- Fixed pub.dev analyzer warnings.
- Added missing dartdoc comments for public APIs.
- Updated homepage URL.
1.0.1 #
- Minor bug fixes and improvements.
1.0.0 #
- Initial release of the Stunning UI toolkit.
