add navigate function