lerp static method

Implementation

static ZeroSnackbarAlertStyle lerp(
    ZeroSnackbarAlertStyle? a, ZeroSnackbarAlertStyle? b, double t) {
  return ZeroSnackbarAlertStyle(
    duration: t < 0.5 ? a?.duration : b?.duration,
    border: BorderSide.lerp(
        a?.border ?? BorderSide.none, b?.border ?? BorderSide.none, t),
    titleStyle: TextStyle.lerp(a?.titleStyle, b?.titleStyle, t),
    subtitleStyle: TextStyle.lerp(a?.subtitleStyle, b?.subtitleStyle, t),
    padding: EdgeInsetsGeometry.lerp(a?.padding, b?.padding, t),
    margin: EdgeInsetsGeometry.lerp(a?.margin, b?.margin, t),
    borderRadius:
        BorderRadiusGeometry.lerp(a?.borderRadius, b?.borderRadius, t),
    iconSize: t < 0.5 ? a?.iconSize : b?.iconSize,
    color: Color.lerp(a?.color, b?.color, t),
    defaultDangerColor:
        Color.lerp(a?.defaultDangerColor, b?.defaultDangerColor, t),
    defaultWarningColor:
        Color.lerp(a?.defaultWarningColor, b?.defaultWarningColor, t),
    defaultInfoColor: Color.lerp(a?.defaultInfoColor, b?.defaultInfoColor, t),
    defaultSuccessColor:
        Color.lerp(a?.defaultSuccessColor, b?.defaultSuccessColor, t),
  );
}