How to build a navigation menu for long-form texts like this one

What you might be looking for is http://scrollnav.com.

We use this for Aesop Story Engine in our Chapter and Timeline components.

tech