refactor(navbar): improve readability, remove duplication