lerp method

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

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

Implementation

@useResult
FTappableStyle lerp(FTappableStyle other, double t) => FTappableStyle(
  cursor: t < 0.5 ? cursor : other.cursor,
  pressedEnterDuration: t < 0.5 ? pressedEnterDuration : other.pressedEnterDuration,
  pressedExitDuration: t < 0.5 ? pressedExitDuration : other.pressedExitDuration,
  motion: motion.lerp(other.motion, t),
);