Skip to content

showSelectedLabels true not working still when tab selected its label is not shoiwng  #37

Description

@sunil-singh-chaudhary

child: SnakeNavigationBar.color(
behaviour: snakeBarStyle,
snakeViewColor: selectedColor,
unselectedItemColor: Colors.blueGrey,
showUnselectedLabels: showUnselectedLabels,
showSelectedLabels: true,
currentIndex: _selectedItemPosition,
selectedLabelStyle: TextStyle(fontSize: 12.sp),
unselectedLabelStyle: TextStyle(fontSize: 10.sp),
// BOTTOm NAVIGATION POSITION HANDlE
onTap: (value) {
setState(() {
_selectedItemPosition = value;
});

                    debugPrint('tapped on $value');
                    if (value == 0) {
                      homeController.isSelectedBottomIcon = 1;
                      homeController.update();
                    }
                    if (value == 1) {
                      showCuprtinoLiveDialog();
                    }
                    if (value == 2) {
                      _handlevalue2();
                    }
                    if (value == 3) {
                      _handlevalue3();
                    }
                  },
                  items: [
                    BottomNavigationBarItem(
                        icon: SizedBox(
                          height: 25,
                          width: 25,
                          child: Image.asset(
                            'assets/images/bottombaricons/home.png',
                          ),
                        ),
                        label: tr('Home')),
                    BottomNavigationBarItem(
                        icon: SizedBox(
                          height: 25,
                          width: 25,
                          child: Image.asset(
                            'assets/images/bottombaricons/live.png',
                          ),
                        ),
                        label: tr('Live')),
                    BottomNavigationBarItem(
                        icon: SizedBox(
                          height: 25,
                          width: 25,
                          child: Image.asset(
                            'assets/images/bottombaricons/history.png',
                          ),
                        ),
                        label: tr('History')),
                    BottomNavigationBarItem(
                        icon: SizedBox(
                          height: 25,
                          width: 25,
                          child: Image.asset(
                            'assets/images/bottombaricons/profile-user.png',
                          ),
                        ),
                        label: tr('Profile')),
                  ],
                ),
              ),

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions