getIcon function

Widget getIcon(
  1. S360fToastType type,
  2. Color color
)

Implementation

Widget getIcon(S360fToastType type, Color color) {
  final size = S360fDimension.getSpacing(multiplier: 2.5);
  switch (type) {
    case S360fToastType.error:
      return Icon(MingCuteIcons.mgc_warning_line, color: color, size: size);
    case S360fToastType.info:
      return Icon(MingCuteIcons.mgc_information_line, color: color, size: size);
    case S360fToastType.warning:
      return Icon(MingCuteIcons.mgc_warning_line, color: color, size: size);
    case S360fToastType.success:
      return Icon(
        MingCuteIcons.mgc_check_circle_line,
        color: color,
        size: size,
      );
  }
}