copyWith method

  1. @override
GlassTheme copyWith({
  1. double? blurSigma,
  2. double? borderOpacity,
  3. double? surfaceOpacity,
  4. Color? borderColor,
  5. Color? surfaceColor,
})
override

Creates a copy of this theme extension with the given fields replaced by the non-null parameter values.

Implementation

@override
GlassTheme copyWith({
  double? blurSigma,
  double? borderOpacity,
  double? surfaceOpacity,
  Color? borderColor,
  Color? surfaceColor,
}) {
  return GlassTheme(
    blurSigma: blurSigma ?? this.blurSigma,
    borderOpacity: borderOpacity ?? this.borderOpacity,
    surfaceOpacity: surfaceOpacity ?? this.surfaceOpacity,
    borderColor: borderColor ?? this.borderColor,
    surfaceColor: surfaceColor ?? this.surfaceColor,
  );
}