Is it possible to not change the selected index when the circle button is selected? for example:
bottomNavigationBar: ConvexAppBar(
style: TabStyle.fixedCircle,
height: 60,
backgroundColor: Color.fromARGB(255, 26, 26, 26),
activeColor: Colors.orange,
items: [
TabItem(icon: Icons.home, title: 'Home'),
TabItem(icon: Icons.folder_shared, title: 'Models'),
TabItem(icon: Icons.add, title: 'Add'),
TabItem(icon: Icons.camera_indoor, title: 'Studios'),
TabItem(icon: Icons.perm_media, title: 'Shoots'),
],
onTap: (index) => {
print('click $index'),
// check if index is the add button, and if so don't do anything
if (index < 2) {
controller.jumpToPage((index))
} else if (index >2) {
controller.jumpToPage((index - 1))
} else {
print('Add button clicked'),
}
},
)
If the 1st, 2nd, 4th or 5th bar icons are selected, I want them to stay selected, but allow the middle "+" button to create new items on the selected page, similar to the how venmo works:
the pay/request button in the middle launches a new page, but hitting "back" on your device still has home/cards/crypto/me selected. In otherwords ,the center icon should just function as a action item to do something, not change index on the bottom navigation bar. Thanks!
This is with the latest version of the convex_bottom_bar, fyi.
Is it possible to not change the selected index when the circle button is selected? for example:
If the 1st, 2nd, 4th or 5th bar icons are selected, I want them to stay selected, but allow the middle "+" button to create new items on the selected page, similar to the how venmo works:
the pay/request button in the middle launches a new page, but hitting "back" on your device still has home/cards/crypto/me selected. In otherwords ,the center icon should just function as a action item to do something, not change index on the bottom navigation bar. Thanks!
This is with the latest version of the convex_bottom_bar, fyi.