RollingNavBar.iconData constructor
RollingNavBar.iconData(- {@required List<IconData> iconData,
- List<Color> activeBadgeColors,
- List<Color> activeIconColors,
- int activeIndex = 0,
- Curve animationCurve = Curves.linear,
- AnimationType animationType = AnimationType.roll,
- List<Widget> badges,
- int baseAnimationSpeed = 200,
- List<Color> iconColors = const <Color>[Colors.black],
- double iconSize,
- List<Widget> iconText,
- List<Color> indicatorColors = const <Color>[Colors.pink],
- double indicatorCornerRadius = 10,
- double indicatorRadius = 25,
- int indicatorSides = 6,
- BoxDecoration navBarDecoration,
- dynamic onAnimate(
- AnimationUpdate
),
- dynamic onTap(
- int
),
- double sidesPerListItem}
)
Implementation
RollingNavBar.iconData({
@required this.iconData,
this.activeBadgeColors,
this.activeIconColors,
this.activeIndex = 0,
this.animationCurve = Curves.linear,
this.animationType = AnimationType.roll,
this.badges,
this.baseAnimationSpeed = 200,
this.iconColors = const <Color>[Colors.black],
this.iconSize,
this.iconText,
this.indicatorColors = const <Color>[Colors.pink],
this.indicatorCornerRadius = 10,
this.indicatorRadius = 25,
this.indicatorSides = 6,
this.navBarDecoration,
this.onAnimate,
this.onTap,
this.sidesPerListItem,
}) : numChildren = iconData.length,
builder = null,
assert(iconText == null || iconText.length == iconData.length),
assert(indicatorSides > 2),
assert(activeBadgeColors == null ||
activeBadgeColors.length == 1 ||
activeBadgeColors.length == iconData.length),
assert(activeIconColors == null ||
activeIconColors.length == 1 ||
activeIconColors.length == iconData.length),
assert(badges == null || badges.length == iconData.length),
assert(iconColors.length == 1 || iconColors.length == iconData.length),
assert(indicatorColors.length == 1 ||
indicatorColors.length == iconData.length);