lerp method

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

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

Implementation

@useResult
FSidebarItemMotion lerp(FSidebarItemMotion other, double t) => FSidebarItemMotion(
  expandDuration: t < 0.5 ? expandDuration : other.expandDuration,
  collapseDuration: t < 0.5 ? collapseDuration : other.collapseDuration,
  expandCurve: t < 0.5 ? expandCurve : other.expandCurve,
  collapseCurve: t < 0.5 ? collapseCurve : other.collapseCurve,
  fadeInCurve: t < 0.5 ? fadeInCurve : other.fadeInCurve,
  fadeOutCurve: t < 0.5 ? fadeOutCurve : other.fadeOutCurve,
  iconExpandCurve: t < 0.5 ? iconExpandCurve : other.iconExpandCurve,
  iconCollapseCurve: t < 0.5 ? iconCollapseCurve : other.iconCollapseCurve,
  revealTween: t < 0.5 ? revealTween : other.revealTween,
  fadeTween: t < 0.5 ? fadeTween : other.fadeTween,
  iconTween: t < 0.5 ? iconTween : other.iconTween,
);