Update documentation.
Refactor TOC generation.