PhoenixTabBar constructor
PhoenixTabBar({
- required List<
BadgeTab> ? tabs, - BrnTabBarBadgeMode mode = BrnTabBarBadgeMode.average,
- bool isScroll = false,
- double? tabHeight,
- EdgeInsetsGeometry padding = EdgeInsets.zero,
- TabController? controller,
- Color backgroundcolor = const Color(0xffffffff),
- Color? indicatorColor,
- double? indicatorWeight,
- double? indicatorWidth,
- EdgeInsetsGeometry indicatorPadding = EdgeInsets.zero,
- Color? labelColor,
- TextStyle? labelStyle,
- EdgeInsetsGeometry labelPadding = EdgeInsets.zero,
- Color? unselectedLabelColor,
- TextStyle? unselectedLabelStyle,
- DragStartBehavior dragStartBehavior = DragStartBehavior.start,
- TabBarOnTap? onTap,
- double? tabWidth,
- bool hasDivider = false,
- bool hasIndex = false,
- bool showMore = false,
- String? moreWindowText,
- VoidCallback? onMorePop,
- CloseWindowController? closeController,
- BaseTabBarConfig? themeData,
- double? tagSpacing,
- int? preLineTagCount,
- double? tagHeight,
Implementation
PhoenixTabBar({
required this.tabs,
this.mode = BrnTabBarBadgeMode.average,
this.isScroll = false,
this.tabHeight,
this.padding = EdgeInsets.zero,
this.controller,
this.backgroundcolor = const Color(0xffffffff),
this.indicatorColor,
this.indicatorWeight,
this.indicatorWidth,
this.indicatorPadding = EdgeInsets.zero,
this.labelColor,
this.labelStyle,
this.labelPadding = EdgeInsets.zero,
this.unselectedLabelColor,
this.unselectedLabelStyle,
this.dragStartBehavior = DragStartBehavior.start,
this.onTap,
this.tabWidth,
this.hasDivider = false,
this.hasIndex = false,
this.showMore = false,
this.moreWindowText,
this.onMorePop,
this.closeController,
this.themeData,
this.tagSpacing,
this.preLineTagCount,
this.tagHeight,
}) : assert(tabs != null) {
themeData ??= BaseTabBarConfig();
themeData = BaseThemeConfig.instance
.getConfig(configId: themeData!.configId)
.tabBarConfig
.merge(themeData);
themeData = themeData!.merge(BaseTabBarConfig(
backgroundColor: backgroundcolor,
tabHeight: tabHeight,
indicatorHeight: indicatorWeight,
indicatorWidth: indicatorWidth,
labelStyle: BaseTextStyle.withStyle(labelStyle),
unselectedLabelStyle: BaseTextStyle.withStyle(unselectedLabelStyle),
tagSpacing: tagSpacing,
preLineTagCount: preLineTagCount,
tagHeight: tagHeight,
));
}