I want to change the color of the selected area in the bottom navigation view material 3, but the color does not change in any way. I've tried selector, background, background Tint, and styles. All unsuccessfully.
How to change the color of active indicator bottombavigationview material You? material3
8.7k Views Asked by antnbaranov At
2
There are 2 best solutions below
1

you can use this function for change indicator color:
findViewById<BottomNavigationView>(R.id.bottomNavigationView) .itemActiveIndicatorColor = getColorStateList(R.color.white)
and set this annotatin for your onCreate function @RequiresApi(Build.VERSION_CODES.M)
look in the screenshot
You can change indicator color by overridng it's default style.
Default itemIndicatorStyle :
just override the style according to your preference :
And then add this line to your bottomNavigationView xml code :