SafaehSheetDataLoader<T extends Object> constructor

const SafaehSheetDataLoader<T extends Object>({
  1. Key? key,
  2. required FutureOr<T> load(
    1. bool retry
    ),
  3. required Widget builder(
    1. BuildContext context,
    2. T data
    ),
  4. T? initialData,
  5. Widget? header,
  6. IconData icon = Icons.hourglass_top_rounded,
  7. SafaehSheetLoadLabels labels = const SafaehSheetLoadLabels(),
  8. Duration timeout = const Duration(seconds: 20),
  9. void onError(
    1. Object error,
    2. StackTrace stack
    )?,
  10. WidgetBuilder? loadingBuilder,
  11. Widget errorBuilder(
    1. BuildContext context,
    2. Object error,
    3. StackTrace stack,
    4. VoidCallback retry,
    )?,
  12. Key? retryKey,
  13. EdgeInsetsGeometry? padding,
})

Implementation

const SafaehSheetDataLoader({
  super.key,
  required this.load,
  required this.builder,
  this.initialData,
  this.header,
  this.icon = Icons.hourglass_top_rounded,
  this.labels = const SafaehSheetLoadLabels(),
  this.timeout = const Duration(seconds: 20),
  this.onError,
  this.loadingBuilder,
  this.errorBuilder,
  this.retryKey,
  this.padding,
});