Refactor navigation scrolling code and update button text