jb3rndt / PersistentBottomNavBarV2

A highly customizable persistent bottom navigation bar for Flutter
https://pub.dev/packages/persistent_bottom_nav_bar_v2
BSD 3-Clause "New" or "Revised" License
47 stars 48 forks source link

backgroundColor not working #128

Closed HamzaAssassin closed 5 days ago

HamzaAssassin commented 3 months ago

When I used to modify the background color, it didn't change the background color. but when I used to hide the bottom navigation bar, the background color didn't hide with the bottom navigation bar. WhatsApp Image 2024-03-14 at 13 34 15_2ac65cdd

jb3rndt commented 3 months ago

I think you just upgraded to version 5 right? PersistentTabView.backgroundColor now sets the color of the whole PersistentTabView, instead of just the navbar like in version 4. If you want to change the background of your navigation bar, pass a NavBarDecoration object to the navBarDecoration argument of the navbar and change the color in that object. Or, if you are using a custom navbar, change your code accordingly.

Regarding the background not hiding: I dont know how that is caused. Please send me a small code sample that reproduces this issue (including at least your PersistentTabView configuration, the code for the navbar if you use a custom one, the configuration for the tabs and if relevant the logic for hiding the navbar). If your code contains anything that should not be shared, replace it with a placeholder, but please keep the code executable.