ButtonSplashStyle class

ButtonSplashStyle defines customizable splash effects for buttons. Use factory constructors to create different splash styles.

Constructors

ButtonSplashStyle.custom({required InteractiveInkFeatureFactory splashFactory, Color? splashColor, Color? highlightColor, double splashOpacity = 0.12, double highlightOpacity = 0.06, BorderRadius? borderRadius, bool bounded = true, WidgetStateProperty<Color?>? overlayColor})
Custom splash with full control
factory
ButtonSplashStyle.glow({Color? glowColor, double glowOpacity = 0.15, BorderRadius? borderRadius, WidgetStateProperty<Color?>? overlayColor})
Soft glow effect that radiates from touch point Creates a softer, more organic feel
factory
ButtonSplashStyle.highlight({Color? highlightColor, double highlightOpacity = 0.08, BorderRadius? borderRadius, WidgetStateProperty<Color?>? overlayColor})
Subtle highlight effect without ripple animation Good for minimal/clean designs
factory
ButtonSplashStyle.ink({Color? inkColor, double inkOpacity = 0.1, BorderRadius? borderRadius, WidgetStateProperty<Color?>? overlayColor})
Quick ink splash effect Faster, more responsive feel
factory
ButtonSplashStyle.none()
No splash effect Clean press without visual feedback (use with animations instead)
const
ButtonSplashStyle.ripple({Color? splashColor, Color? highlightColor, double splashOpacity = 0.12, double highlightOpacity = 0.06, BorderRadius? borderRadius, WidgetStateProperty<Color?>? overlayColor})
Standard Material ripple effect (default) Circular ripple expands from touch point
factory

Properties

animationDuration → Duration?
final
borderRadius → BorderRadius?
final
bounded → bool
final
hashCode → int
The hash code for this object.
no setterinherited
highlightColor → Color?
final
highlightOpacity → double?
final
overlayColor → WidgetStateProperty<Color?>?
Optional overlay color for WidgetStateProperty-based control. When set, this takes precedence over splashColor/highlightColor.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
splashColor → Color?
final
splashFactory → InteractiveInkFeatureFactory?
final
splashOpacity → double?
final
type → ButtonSplashType
final

Methods

copyWith({ButtonSplashType? type, Color? splashColor, Color? highlightColor, double? splashOpacity, double? highlightOpacity, BorderRadius? borderRadius, bool? bounded, Duration? animationDuration, InteractiveInkFeatureFactory? splashFactory, WidgetStateProperty<Color?>? overlayColor}) → ButtonSplashStyle
Create a copy with modified properties
getHighlightColor(BuildContext context, Color fallbackColor) → Color
Get the resolved highlight color with opacity applied
getOverlayColor() → WidgetStateProperty<Color?>?
Get the resolved overlay color for InkWell. Returns transparent for ButtonSplashType.none to fully disable feedback.
getSplashColor(BuildContext context, Color fallbackColor) → Color
Get the resolved splash color with opacity applied
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited