FloatyNavyBar constructor

FloatyNavyBar({
  1. Key? key,
  2. required List<NavyBarItem> items,
  3. required ValueChanged<int> onChanged,
  4. required double barHeight,
  5. Color? iconColor,
  6. double? iconSize,
  7. TextStyle? textStyle,
  8. Color? backgroundColor,
  9. Color indicatorColor = Colors.black,
  10. double indicatorHeight = 5.0,
  11. double indicatorWidth = 8.0,
  12. double itemWidth = 70,
})

Implementation

FloatyNavyBar({
  Key? key,
  required this.items,
  required this.onChanged,
  required this.barHeight,
  this.iconColor,
  this.iconSize,
  this.textStyle,
  this.backgroundColor,
  this.indicatorColor = Colors.black,
  this.indicatorHeight = 5.0,
  this.indicatorWidth = 8.0,
  this.itemWidth = 70,
})  : assert(items.length > 1 && items.length < 5,
          "\n******\n NavBarItems can't contain only 1 item and can't exceed 4 items \n******\n"),
      assert(
        indicatorWidth <= 15 || indicatorHeight <= 15,
        "\n******\n Too much height given to tab indicator \n******\n",
      ),
      super(key: key);