Migration improvements

Care is taken to let the progress bar run all the way, in the past failures caused it to stop short.

Since we'll mostly be doing xhtml migrations, this adds a utils module with a factory method that creates migrations for xhtml modules, so you only have to write a bit of jquery code to transform the passed $body object.

If anything fails, the migration continues, but the progress bar turns red to visually indicate that something was wrong.

Errors in migration is shown in a popover.

This supersedes #135.