FloatyTab constructor
const
FloatyTab({
- required bool isSelected,
- required String title,
- required VoidCallback onTap,
- required Widget icon,
- TextStyle? titleStyle,
- FloatyActionButton? floatyActionButton,
- EdgeInsetsGeometry margin = const EdgeInsets.all(4),
- Color? selectedColor,
- Color? unselectedColor,
Creates a FloatyTab instance with the specified properties.
The isSelected
parameter indicates whether the tab is currently selected.
The title
parameter sets the text displayed on the tab.
The onTap
parameter is a callback function that is invoked when the tab is tapped.
The icon
parameter specifies the icon displayed on the tab.
The titleStyle
parameter allows customization of the text style for the title.
The floatyActionButton
parameter can be used to associate a floating action button with the tab.
The margin
parameter sets the margin around the tab, defaulting to 4 pixels on all sides.
The selectedColor
and unselectedColor
parameters define the colors of the tab in selected
and unselected states respectively.
Implementation
const FloatyTab({
required this.isSelected,
required this.title,
required this.onTap,
required this.icon,
this.titleStyle,
this.floatyActionButton,
this.margin = const EdgeInsets.all(4),
this.selectedColor,
this.unselectedColor,
});