of static method

Implementation

static BoxConstraints of(BuildContext context) {
  final provider =
      context.dependOnInheritedWidgetOfExactType<SlideConstraintsProvider>();
  if (provider == null) {
    throw FlutterError('SlideConstraintsProvider not found in context');
  }

  return provider.constraints;
}