animateWidgetBorderGlow method
Widget
animateWidgetBorderGlow(
{ - Color color = Colors.greenAccent,
- int durationMs = 2000,
- bool repeat = true,
- bool animate = true,
})
Implementation
Widget animateWidgetBorderGlow(
{Color color = Colors.greenAccent,
int durationMs = 2000,
bool repeat = true,
bool animate = true}) {
if (!animate) return this;
return _baseAnimate(repeat: repeat, reverse: true).custom(
duration: durationMs.ms,
builder: (_, v, child) => Container(
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(12),
border: Border.all(
color: color.withColorOpacity(0.1 + (0.5 * v)),
width: 1 + (2 * v)),
),
child: child,
),
);
}