add button to toggle the optional theme when viewing the docs

Fixes #9764.
The button is only present on relevant pages of the docs. I didn't notice any undesirable effects on docs-specific styling.
/cc @twbs/team for review.