I have a BottomNavigationView setup with Navigation Component, and I want to intercept the handling of changing destinations on pressing an item, and prevent it from changing destination on a certain condition.
For example: Showing a dialog if the user is navigating to a destination and he's not signed in.
How do I do that?
I can't seem to be finding a listener that could be called OnDestinationChange with some sort of boolean returned to inform the navigation component that it should go ahead with the navigation or not.