copyWith method

  1. @override
M3ETheme copyWith({
  1. M3EColors? colors,
  2. M3ETypography? typography,
  3. M3EShapes? shapes,
  4. M3ESpacing? spacing,
  5. M3EMotion? motion,
})
override

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

Implementation

@override
M3ETheme copyWith({
  M3EColors? colors,
  M3ETypography? typography,
  M3EShapes? shapes,
  M3ESpacing? spacing,
  M3EMotion? motion,
}) =>
    M3ETheme(
      colors: colors ?? this.colors,
      typography: typography ?? this.typography,
      shapes: shapes ?? this.shapes,
      spacing: spacing ?? this.spacing,
      motion: motion ?? this.motion,
    );