Refactor navbar class for the sake of the example