AnimatedTextBar constructor
AnimatedTextBar({
- Key? key,
- required List<
BarItem> items, - ValueChanged<
int> ? onTap, - int currentIndex = 0,
- double? elevation,
- Color? backgroundColor,
- Color? shadowColor,
- Duration animatedTextDuration = const Duration(milliseconds: 250),
- Curve animatedTextCurve = Curves.easeInOut,
- TextStyle? selectedLabelStyle,
- TextStyle? unselectedLabelStyle,
- EdgeInsetsGeometry? margin,
- EdgeInsetsGeometry? padding,
- BorderRadiusGeometry? borderRadius,
- TextPosition textPosition = TextPosition.RIGHT,
- Color? selectedItemColor,
- Color? unselectedItemColor,
- BorderRadiusGeometry? selectedItemBorderRadius,
- double selectedFontSize = 14.0,
- double unselectedFontSize = 12.0,
Creates a animated text bar which is typically used as a Scaffold's Scaffold.bottomNavigationBar argument.
The length of items must be at least two and each item's iconData or image and label must not be null.
elevation argument must be non-negative.
Implementation
AnimatedTextBar({
Key? key,
required this.items,
this.onTap,
this.currentIndex = 0,
this.elevation,
this.backgroundColor,
this.shadowColor,
this.animatedTextDuration = const Duration(milliseconds: 250),
this.animatedTextCurve = Curves.easeInOut,
this.selectedLabelStyle,
this.unselectedLabelStyle,
this.margin,
this.padding,
this.borderRadius,
this.textPosition = TextPosition.RIGHT,
this.selectedItemColor,
this.unselectedItemColor,
this.selectedItemBorderRadius,
this.selectedFontSize = 14.0,
this.unselectedFontSize = 12.0,
}) : assert(elevation == null || elevation >= 0.0),
super(key: key);