lerp method

  1. @useResult
FCardStyle lerp(
  1. FCardStyle other,
  2. double t
)

Linearly interpolate between this and another FCardStyle using the given factor t.

Implementation

@useResult
FCardStyle lerp(FCardStyle other, double t) => .new(
  decoration: .lerp(decoration, other.decoration, t) ?? decoration,
  titleTextStyle: .lerp(titleTextStyle, other.titleTextStyle, t) ?? titleTextStyle,
  subtitleTextStyle: .lerp(subtitleTextStyle, other.subtitleTextStyle, t) ?? subtitleTextStyle,
  padding: .lerp(padding, other.padding, t) ?? padding,
);