FloaticaGlassEffect.liquidGlass constructor

const FloaticaGlassEffect.liquidGlass({
  1. double blur = 25.0,
  2. double opacity = 0.12,
  3. Color? tintColor,
  4. Gradient? gradient = const LinearGradient(begin: Alignment.topLeft, end: Alignment.bottomRight, colors: [Color(0x30FFFFFF), Color(0x18FFFFFF), Color(0x10FFFFFF), Color(0x20FFFFFF)], stops: [0.0, 0.3, 0.7, 1.0]),
  5. Color? borderColor = const Color(0x50FFFFFF),
  6. double borderWidth = 0.5,
  7. bool enableShadow = true,
  8. Color? shadowColor = const Color(0x30000000),
  9. double shadowBlur = 20.0,
  10. double shadowSpread = 0.0,
  11. bool specularHighlight = true,
  12. bool innerShadow = true,
  13. double saturationBoost = 1.3,
  14. double noiseOpacity = 0.03,
  15. LiquidGlassVariant variant = LiquidGlassVariant.regular,
  16. double edgeGlowIntensity = 0.6,
})

Creates an iOS 26–style regular Liquid Glass effect.

Features multi-layer specular highlights, shape-aware edge glow, inner shadow, frosted noise texture, and saturation boost to mimic the dynamic Liquid Glass material from iOS 26.

Implementation

const FloaticaGlassEffect.liquidGlass({
  this.blur = 25.0,
  this.opacity = 0.12,
  this.tintColor,
  this.gradient = const LinearGradient(
    begin: Alignment.topLeft,
    end: Alignment.bottomRight,
    colors: [
      Color(0x30FFFFFF),
      Color(0x18FFFFFF),
      Color(0x10FFFFFF),
      Color(0x20FFFFFF),
    ],
    stops: [0.0, 0.3, 0.7, 1.0],
  ),
  this.borderColor = const Color(0x50FFFFFF),
  this.borderWidth = 0.5,
  this.enableShadow = true,
  this.shadowColor = const Color(0x30000000),
  this.shadowBlur = 20.0,
  this.shadowSpread = 0.0,
  this.specularHighlight = true,
  this.innerShadow = true,
  this.saturationBoost = 1.3,
  this.noiseOpacity = 0.03,
  this.variant = LiquidGlassVariant.regular,
  this.edgeGlowIntensity = 0.6,
});