alphagov/manuals-frontend — pull request #49 by alicebartlett (2014-06-12 14:31:37+00:00)
Title: Make h2 in body collapsable

The HMRC schema and the other-types-of-manual schema that is produced by https://github.com/alphagov/specialist-publisher are different. HMRC collapsibles are provided already broken down whereas the specialist publisher provides them as a blob of body text.

This commit flattens both types as much as possible to produce the same basic HTML and then uses JavaScript to:
- Determine which h2s should be made into collapsible headings.
- Add required tags around these h2s and attaches collapsible functionality to them.