buildResponsive method

  1. @override
Widget buildResponsive(
  1. BuildContext context,
  2. Breakpoints breakpoint
)
override

Builds with the current Breakpoints. This method will be automatically called when the breakpoint changes.

Implementation

@override
Widget buildResponsive(BuildContext context, Breakpoints breakpoint) {
  final boxDecoration = data.getForBreakpoint(breakpoint);

  return DecoratedBox(
    decoration: boxDecoration ?? const BoxDecoration(),
    child: child,
  );
}