TranslucentNavigationBar constructor
TranslucentNavigationBar({
- Key? key,
- required List<
TranslucentNavigationBarItem> items, - Color selectedColor = Colors.black,
- Color unselectedColor = Colors.black26,
- required int selectedIndex,
- Color mainIconBackgroundColor = Colors.blue,
- Color mainIconColor = Colors.white,
- required dynamic onTap()?,
- dynamic onMainIconTap()?,
- double height = 75.0,
- double borderRadius = 40.0,
- double blur = 20.0,
- double verticalPadding = 25.0,
- double horizontalPadding = 20.0,
Implementation
TranslucentNavigationBar({
Key? key,
required this.items,
this.selectedColor = Colors.black,
this.unselectedColor = Colors.black26,
required this.selectedIndex,
this.mainIconBackgroundColor = Colors.blue,
this.mainIconColor = Colors.white,
required this.onTap,
this.onMainIconTap,
this.height = 75.0,
this.borderRadius = 40.0,
this.blur = 20.0,
this.mainTranslucentNavigationBarItem,
this.verticalPadding = 25.0,
this.horizontalPadding = 20.0,
}) : assert(items.length >= 2),
assert(items.length <= 6),
assert(mainTranslucentNavigationBarItem != null
? items.length.isEven
: items.isNotEmpty);