builder static method

Widget builder({
  1. Key? key,
  2. bool isLoading = false,
  3. required TabController? controller,
  4. required void onTap(
    1. int index
    )?,
  5. required int itemCount,
  6. required Widget builder(
    1. bool isActiveOrSelected,
    2. int index
    ),
  7. bool isScrollable = false,
  8. EdgeInsetsGeometry? padding,
  9. Color? indicatorColor,
  10. bool automaticIndicatorColorAdjustment = true,
  11. double indicatorWeight = 2.0,
  12. EdgeInsetsGeometry indicatorPadding = EdgeInsets.zero,
  13. Decoration? indicator,
  14. TabBarIndicatorSize? indicatorSize,
  15. Color? dividerColor,
  16. double? dividerHeight,
  17. Color? labelColor,
  18. TextStyle? labelStyle,
  19. EdgeInsetsGeometry? labelPadding,
  20. Color? unselectedLabelColor,
  21. TextStyle? unselectedLabelStyle,
  22. DragStartBehavior dragStartBehavior = DragStartBehavior.start,
  23. WidgetStateProperty<Color?>? overlayColor,
  24. MouseCursor? mouseCursor,
  25. bool? enableFeedback,
  26. ScrollPhysics? physics,
  27. InteractiveInkFeatureFactory? splashFactory,
  28. BorderRadius? splashBorderRadius,
  29. TabAlignment? tabAlignment,
})

UncompleteDocumentation

Implementation

static Widget builder({
  Key? key,
  bool isLoading = false,
  required TabController? controller,
  required void Function(int index)? onTap,
  required int itemCount,
  required Widget Function(bool isActiveOrSelected, int index) builder,
  bool isScrollable = false,
  EdgeInsetsGeometry? padding,
  Color? indicatorColor,
  bool automaticIndicatorColorAdjustment = true,
  double indicatorWeight = 2.0,
  EdgeInsetsGeometry indicatorPadding = EdgeInsets.zero,
  Decoration? indicator,
  TabBarIndicatorSize? indicatorSize,
  Color? dividerColor,
  double? dividerHeight,
  Color? labelColor,
  TextStyle? labelStyle,
  EdgeInsetsGeometry? labelPadding,
  Color? unselectedLabelColor,
  TextStyle? unselectedLabelStyle,
  DragStartBehavior dragStartBehavior = DragStartBehavior.start,
  WidgetStateProperty<Color?>? overlayColor,
  MouseCursor? mouseCursor,
  bool? enableFeedback,
  ScrollPhysics? physics,
  InteractiveInkFeatureFactory? splashFactory,
  BorderRadius? splashBorderRadius,
  TabAlignment? tabAlignment,
}) {
  final int index = controller!.index;
  return TabbarGeneralFrameworkWidget(
    key: key,
    isLoading: isLoading,
    controller: controller,
    onTap: onTap,
    tabs: [
      for (var i = 0; i < itemCount; i++) ...[
        builder(index == i, i),
      ],
    ],
    isScrollable: isScrollable,
    padding: padding,
    indicatorColor: indicatorColor,
    automaticIndicatorColorAdjustment: automaticIndicatorColorAdjustment,
    indicatorWeight: indicatorWeight,
    indicatorPadding: indicatorPadding,
    indicator: indicator,
    indicatorSize: indicatorSize,
    dividerColor: dividerColor,
    dividerHeight: dividerHeight,
    labelColor: labelColor,
    labelStyle: labelStyle,
    labelPadding: labelPadding,
    unselectedLabelColor: unselectedLabelColor,
    unselectedLabelStyle: unselectedLabelStyle,
    dragStartBehavior: dragStartBehavior,
    overlayColor: overlayColor,
    mouseCursor: mouseCursor,
    enableFeedback: enableFeedback,
    physics: physics,
    splashFactory: splashFactory,
    splashBorderRadius: splashBorderRadius,
    tabAlignment: tabAlignment,
  );
}