getIt static method

Widget getIt(
  1. BuildContext context,
  2. AppModel app,
  3. VoidCallback? callOnAction,
  4. WorkflowModel appBarModel,
  5. bool create,
  6. double widgetWidth,
)

Implementation

static Widget getIt(
  BuildContext context,
  AppModel app,
  VoidCallback? callOnAction,
  WorkflowModel appBarModel,
  bool create,
  double widgetWidth,
) {
  return BlocProvider<WorkflowCreateBloc>(
    create: (context) =>
        WorkflowCreateBloc(app.documentID, appBarModel, callOnAction)
          ..add(WorkflowCreateEventValidateEvent(appBarModel)),
    child: WorkflowCreateWidget._(
      app: app,
      create: create,
      widgetWidth: widgetWidth,
    ),
  );
}