SwitchTab constructor
const
SwitchTab({
- Key? key,
- required dynamic onValueChanged(),
- required List<
String> text, - Color? backgroundColour = Colors.white,
- Color? thumbColor = Colors.lightBlueAccent,
- List<
Widget> ? icon, - SwitchTabShape shape = SwitchTabShape.rounded,
- Color selectedTextColor = Colors.black,
- Color unselectedTextColor = Colors.black,
- TextStyle? style,
Implementation
const SwitchTab({
Key? key,
required this.onValueChanged,
required this.text,
this.backgroundColour = Colors.white,
this.thumbColor = Colors.lightBlueAccent,
this.icon,
this.shape = SwitchTabShape.rounded,
this.selectedTextColor = Colors.black,
this.unselectedTextColor = Colors.black,
this.style,
}) : assert(text.length <= 2, "Must not more than 2"),
super(key: key);