VID-1888 Add hook to add type='navigation' to galleries if needed

This seems to be doing what [this method](https://github.com/Wikia/app/blob/dev/maintenance/wikia/VideoHandlers/markNavGalleries.php#L138-L145) does. Why not move it to a common library to avoid code duplication.