lerp static method
Linearly interpolates between two blockquote styles.
Implementation
static BlockQuoteStyle? lerp(
BlockQuoteStyle? a,
BlockQuoteStyle? b,
double t,
) {
if (a == null && b == null) {
return null;
}
if (a == null) {
return t < 0.5 ? null : b;
}
if (b == null) {
return t < 0.5 ? a : null;
}
return BlockQuoteStyle(
barWidth: lerpDouble(a.barWidth, b.barWidth, t),
barColor: Color.lerp(a.barColor, b.barColor, t),
barRadius: Radius.lerp(a.barRadius, b.barRadius, t),
backgroundColor: Color.lerp(a.backgroundColor, b.backgroundColor, t),
padding: EdgeInsetsGeometry.lerp(a.padding, b.padding, t),
margin: EdgeInsetsGeometry.lerp(a.margin, b.margin, t),
textStyle: TextStyle.lerp(a.textStyle, b.textStyle, t),
);
}