Closed EriKWDev closed 3 years ago
...
SalomonBottomBarItem(
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(10)
),
icon: const Icon(Icons.home_outlined),
title: const Text("Home"),
),
...
or
...
SalomonBottomBar(
itemShape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(10)
),
currentIndex: _currentIndex,
onTap: (i) => setState(() => _currentIndex = i),
items: [
...
Sure thing! I was a bit unsure wether to create a PR or not since I read that we should only do so if it doesn't conform to the spec, but I thought this could be a small and useful customisation for anyone wanting to use it :)
I agree it might be weird to have different shapes per item, but added it just in case. The global shape for every item is all I needed for my purposes. I'll fix it!
This PR adds support for custom item shapes other than just StadiumBorder. It can be specified per item or for all items. Mimicking the behaviour of the other parameters, the shape specified on each item takes priority over the shape defined for that BottomBar.
Example shape could be