refactor for navigation