FlexiChipStyle.toned constructor

FlexiChipStyle.toned({
  1. double? height,
  2. EdgeInsetsGeometry? margin,
  3. EdgeInsetsGeometry? padding,
  4. Clip? clipBehavior,
  5. Color? overlayColor,
  6. Color? shadowColor,
  7. double? elevation,
  8. TextStyle? foregroundStyle,
  9. Color? foregroundColor,
  10. double? foregroundOpacity,
  11. int? foregroundAlpha,
  12. double? foregroundSpacing,
  13. Color? backgroundColor,
  14. double? backgroundOpacity = .12,
  15. int? backgroundAlpha,
  16. Color? borderColor,
  17. double? borderOpacity = 1,
  18. int? borderAlpha,
  19. double? borderWidth = 1,
  20. BorderRadiusGeometry? borderRadius,
  21. BorderStyle? borderStyle = BorderStyle.none,
  22. Size? avatarSize,
  23. TextStyle? avatarForegroundStyle,
  24. Color? avatarForegroundColor,
  25. Color? avatarBackgroundColor,
  26. BorderRadiusGeometry? avatarBorderRadius,
  27. Color? checkmarkColor,
  28. double? checkmarkSize,
  29. double? checkmarkWeight,
  30. FlexiChipCheckmarkStyle? checkmarkStyle,
  31. Color? iconColor,
  32. double? iconOpacity,
  33. double? iconSize,
  34. FlexiChipStyle? selectedStyle,
  35. FlexiChipStyle? disabledStyle = const FlexiChipStyle(foregroundAlpha: FlexiChipStyle.disabledForegroundAlpha, backgroundAlpha: FlexiChipStyle.disabledBackgroundAlpha, borderAlpha: FlexiChipStyle.disabledBorderAlpha),
  36. FlexiChipStyle? hoveredStyle,
  37. FlexiChipStyle? focusedStyle,
  38. FlexiChipStyle? pressedStyle,
})

Create chip's style with default value for toned style.

The selectedStyle is style to be merged, when events includes FlexiChipEvent.selected.

The disabledStyle style to be merged, when events includes FlexiChipEvent.disabled.

The hoveredStyle style to be merged, when events includes FlexiChipEvent.hovered.

The focusedStyle style to be merged, when events includes FlexiChipEvent.focused.

The pressedStyle style to be merged, when events includes FlexiChipEvent.pressed.

Implementation

factory FlexiChipStyle.toned({
  double? height,
  EdgeInsetsGeometry? margin,
  EdgeInsetsGeometry? padding,
  Clip? clipBehavior,
  Color? overlayColor,
  Color? shadowColor,
  double? elevation,
  TextStyle? foregroundStyle,
  Color? foregroundColor,
  double? foregroundOpacity,
  int? foregroundAlpha,
  double? foregroundSpacing,
  Color? backgroundColor,
  double? backgroundOpacity = .12,
  int? backgroundAlpha,
  Color? borderColor,
  double? borderOpacity = 1,
  int? borderAlpha,
  double? borderWidth = 1,
  BorderRadiusGeometry? borderRadius,
  BorderStyle? borderStyle = BorderStyle.none,
  Size? avatarSize,
  TextStyle? avatarForegroundStyle,
  Color? avatarForegroundColor,
  Color? avatarBackgroundColor,
  BorderRadiusGeometry? avatarBorderRadius,
  Color? checkmarkColor,
  double? checkmarkSize,
  double? checkmarkWeight,
  FlexiChipCheckmarkStyle? checkmarkStyle,
  Color? iconColor,
  double? iconOpacity,
  double? iconSize,
  FlexiChipStyle? selectedStyle,
  FlexiChipStyle? disabledStyle = const FlexiChipStyle(
    foregroundAlpha: FlexiChipStyle.disabledForegroundAlpha,
    backgroundAlpha: FlexiChipStyle.disabledBackgroundAlpha,
    borderAlpha: FlexiChipStyle.disabledBorderAlpha,
  ),
  FlexiChipStyle? hoveredStyle,
  FlexiChipStyle? focusedStyle,
  FlexiChipStyle? pressedStyle,
}) {
  return FlexiChipStyle.when(
    enabled: FlexiChipStyle(
      height: height,
      margin: margin,
      padding: padding,
      clipBehavior: clipBehavior,
      overlayColor: overlayColor,
      shadowColor: shadowColor,
      elevation: elevation,
      foregroundStyle: foregroundStyle,
      foregroundColor: foregroundColor,
      foregroundOpacity: foregroundOpacity,
      foregroundAlpha: foregroundAlpha,
      foregroundSpacing: foregroundSpacing,
      backgroundColor: backgroundColor,
      backgroundOpacity: backgroundOpacity,
      backgroundAlpha: backgroundAlpha,
      borderColor: borderColor,
      borderOpacity: borderOpacity,
      borderAlpha: borderAlpha,
      borderWidth: borderWidth,
      borderRadius: borderRadius,
      borderStyle: borderStyle,
      avatarSize: avatarSize,
      avatarForegroundStyle: avatarForegroundStyle,
      avatarForegroundColor: avatarForegroundColor,
      avatarBackgroundColor: avatarBackgroundColor,
      avatarBorderRadius: avatarBorderRadius,
      checkmarkColor: checkmarkColor,
      checkmarkSize: checkmarkSize,
      checkmarkWeight: checkmarkWeight,
      checkmarkStyle: checkmarkStyle,
      iconColor: iconColor,
      iconOpacity: iconOpacity,
      iconSize: iconSize,
    ),
    selected: selectedStyle,
    disabled: disabledStyle,
    hovered: hoveredStyle,
    focused: focusedStyle,
    pressed: pressedStyle,
  );
}