ProjectConfig constructor

ProjectConfig({
  1. required Color mainColor,
  2. String betaApi = '',
  3. String releaseApi = '',
  4. RoutePushStyle pushStyle = RoutePushStyle.material,
  5. Header? pullDownHeader,
  6. Footer? pullUpFooter,
  7. Color? scaffoldBackground,
  8. AppBarConfig? appBarConfig,
  9. String? cachePath,
  10. Widget placeholder = const BasicPlaceholder(),
  11. ToastOptions toastOptions = const ToastOptions(positioned: Alignment.topCenter, duration: Duration(seconds: 2), ignoring: true),
  12. DialogOptions? generalDialogOptions,
  13. BottomSheetOptions? bottomSheetOptions,
  14. ModalWindowsOptions? modalWindowsOptions,
  15. bool logCrossLine = true,
  16. WheelOptions? wheelOptions,
  17. ModalWindowsOptions? loadingModalWindowsOptions,
  18. LoadingCoreBuilder? loadingBuilder,
  19. Widget? imageFailed,
  20. TextColor? textColor,
})

Implementation

ProjectConfig({
  required this.mainColor,
  this.betaApi = '',
  this.releaseApi = '',
  this.pushStyle = RoutePushStyle.material,
  this.pullDownHeader,
  this.pullUpFooter,
  this.scaffoldBackground,
  this.appBarConfig,
  this.cachePath,
  this.placeholder = const BasicPlaceholder(),
  this.toastOptions = const ToastOptions(
      positioned: Alignment.topCenter,
      duration: Duration(seconds: 2),
      ignoring: true),
  this.generalDialogOptions,
  this.bottomSheetOptions,
  this.modalWindowsOptions,
  this.logCrossLine = true,
  this.wheelOptions,
  this.loadingModalWindowsOptions,
  this.loadingBuilder,
  this.imageFailed,
  this.textColor,
}) {
  pullDownHeader ??= const ClassicHeader(
      dragText: '请尽情拉我',
      armedText: '可以松开我了',
      readyText: '我要开始刷新了',
      processingText: '我在拼命刷新中',
      processedText: '我已经刷新完成了',
      failedText: '我刷新失败了唉',
      noMoreText: '没有更多了',
      showMessage: false);
  pullUpFooter ??= const ClassicFooter(
      dragText: '请尽情拉我',
      armedText: '可以松开我了',
      readyText: '我要准备加载了',
      processingText: '我在拼命加载中',
      processedText: '我已经加载完成了',
      failedText: '我加载失败了唉',
      noMoreText: '没有更多了哦',
      showMessage: false);
}