MDL-38661 Course: Add JS category expander.

This adds a category expanded which:
* fetches child content in a category tree if it has not already been loaded;
* toggles relevant classes on the category node to show and hide child content; and
* applies appropriate animations to improve user experience.
MDL-38661 Hide collapse/expand if unapplicable