scale method

GetAnimatedBuilder scale({
  1. required double begin,
  2. required double end,
  3. Duration duration = _defaultDuration,
  4. Duration delay = _defaultDelay,
  5. ValueSetter<AnimationController>? onComplete,
  6. bool isSequential = false,
})

Adds a scale animation to the widget.

Example:

myWidget.scale(begin: 0.5, end: 1.5); // Scales from half to 1.5x size

Implementation

GetAnimatedBuilder scale({
  required double begin,
  required double end,
  Duration duration = _defaultDuration,
  Duration delay = _defaultDelay,
  ValueSetter<AnimationController>? onComplete,
  bool isSequential = false,
}) {
  return GetAnimatedBuilder<double>(
    duration: duration,
    delay: _getDelay(isSequential, delay),
    tween: Tween<double>(begin: begin, end: end),
    idleValue: begin,
    onComplete: onComplete,
    builder: (context, value, child) =>
        Transform.scale(scale: value, child: child),
    child: this,
  );
}