refactoring bootstrap navbar directives