Add rep to header. Fixes #519.
Add active state to headers. Fixes #520.