PreferredSizeWidget.tabBar constructor Null safety

const PreferredSizeWidget.tabBar(
  1. {Key? key,
  2. required List<Widget> tabs,
  3. @Default(false) bool isScrollable,
  4. IntSelectionCallback? onTap,
  5. EdgeInsets? padding,
  6. Color? indicatorColor,
  7. @Default(true) bool automaticIndicatorColorAdjustment,
  8. @Default(2.0) double indicatorWeight,
  9. @Default(EdgeInsets.zero) EdgeInsets indicatorPadding,
  10. Decoration? indicator,
  11. TabBarIndicatorSize? indicatorSize,
  12. Color? dividerColor,
  13. Color? labelColor,
  14. TextStyle? labelStyle,
  15. EdgeInsets? labelPadding,
  16. Color? unselectedLabelColor,
  17. TextStyle? unselectedLabelStyle,
  18. @Default(DragStartBehavior.start) DragStartBehavior dragStartBehavior,
  19. MaterialStateProperty? overlayColor,
  20. MouseCursor? mouseCursor,
  21. bool? enableFeedback,
  22. ScrollPhysics? physics,
  23. BorderRadius? splashBorderRadius}
)

Implementation

const factory PreferredSizeWidget.tabBar({
  Key? key,
  required List<Widget> tabs,
  @Default(false) bool isScrollable,
  IntSelectionCallback? onTap,
  EdgeInsets? padding,
  Color? indicatorColor,
  @Default(true) bool automaticIndicatorColorAdjustment,
  @Default(2.0) double indicatorWeight,
  @Default(EdgeInsets.zero) EdgeInsets indicatorPadding,
  Decoration? indicator,
  TabBarIndicatorSize? indicatorSize,
  Color? dividerColor,
  Color? labelColor,
  TextStyle? labelStyle,
  EdgeInsets? labelPadding,
  Color? unselectedLabelColor,
  TextStyle? unselectedLabelStyle,
  @Default(DragStartBehavior.start) DragStartBehavior dragStartBehavior,
  MaterialStateProperty? overlayColor,
  MouseCursor? mouseCursor,
  bool? enableFeedback,
  ScrollPhysics? physics,
  BorderRadius? splashBorderRadius,
}) = TabBar;