copyWith method

StreamColorTheme copyWith({
  1. Brightness brightness = Brightness.light,
  2. Color? textHighEmphasis,
  3. Color? textLowEmphasis,
  4. Color? disabled,
  5. Color? borders,
  6. Color? inputBg,
  7. Color? appBg,
  8. Color? barsBg,
  9. Color? linkBg,
  10. Color? accentPrimary,
  11. Color? accentError,
  12. Color? accentInfo,
  13. Effect? borderTop,
  14. Effect? borderBottom,
  15. Effect? shadowIconButton,
  16. Effect? modalShadow,
  17. Color? highlight,
  18. Color? overlay,
  19. Color? overlayDark,
  20. Gradient? bgGradient,
})

Copy with theme

Implementation

StreamColorTheme copyWith({
  Brightness brightness = Brightness.light,
  Color? textHighEmphasis,
  Color? textLowEmphasis,
  Color? disabled,
  Color? borders,
  Color? inputBg,
  Color? appBg,
  Color? barsBg,
  Color? linkBg,
  Color? accentPrimary,
  Color? accentError,
  Color? accentInfo,
  Effect? borderTop,
  Effect? borderBottom,
  Effect? shadowIconButton,
  Effect? modalShadow,
  Color? highlight,
  Color? overlay,
  Color? overlayDark,
  Gradient? bgGradient,
}) {
  return brightness == Brightness.light
      ? StreamColorTheme.light(
          textHighEmphasis: textHighEmphasis ?? this.textHighEmphasis,
          textLowEmphasis: textLowEmphasis ?? this.textLowEmphasis,
          disabled: disabled ?? this.disabled,
          borders: borders ?? this.borders,
          inputBg: inputBg ?? this.inputBg,
          appBg: appBg ?? this.appBg,
          barsBg: barsBg ?? this.barsBg,
          linkBg: linkBg ?? this.linkBg,
          accentPrimary: accentPrimary ?? this.accentPrimary,
          accentError: accentError ?? this.accentError,
          accentInfo: accentInfo ?? this.accentInfo,
          borderTop: borderTop ?? this.borderTop,
          borderBottom: borderBottom ?? this.borderBottom,
          shadowIconButton: shadowIconButton ?? this.shadowIconButton,
          modalShadow: modalShadow ?? this.modalShadow,
          highlight: highlight ?? this.highlight,
          overlay: overlay ?? this.overlay,
          overlayDark: overlayDark ?? this.overlayDark,
          bgGradient: bgGradient ?? this.bgGradient,
        )
      : StreamColorTheme.dark(
          textHighEmphasis: textHighEmphasis ?? this.textHighEmphasis,
          textLowEmphasis: textLowEmphasis ?? this.textLowEmphasis,
          disabled: disabled ?? this.disabled,
          borders: borders ?? this.borders,
          inputBg: inputBg ?? this.inputBg,
          appBg: appBg ?? this.appBg,
          barsBg: barsBg ?? this.barsBg,
          linkBg: linkBg ?? this.linkBg,
          accentPrimary: accentPrimary ?? this.accentPrimary,
          accentError: accentError ?? this.accentError,
          accentInfo: accentInfo ?? this.accentInfo,
          borderTop: borderTop ?? this.borderTop,
          borderBottom: borderBottom ?? this.borderBottom,
          shadowIconButton: shadowIconButton ?? this.shadowIconButton,
          modalShadow: modalShadow ?? this.modalShadow,
          highlight: highlight ?? this.highlight,
          overlay: overlay ?? this.overlay,
          overlayDark: overlayDark ?? this.overlayDark,
          bgGradient: bgGradient ?? this.bgGradient,
        );
}