frameBuilder static method

Widget frameBuilder(
  1. BuildContext context,
  2. Widget child,
  3. int? frame,
  4. bool wasSynchronouslyLoaded,
)

Implementation

static Widget frameBuilder(BuildContext context, Widget child, int? frame,
    bool wasSynchronouslyLoaded) {
  if (wasSynchronouslyLoaded) {
    return child;
  }
  return AnimatedOpacity(
    opacity: frame == null ? 0 : 1,
    duration: const Duration(seconds: 1),
    curve: Curves.easeOut,
    child: child,
  );
}