Vid 1976

Refactoring the new media galleries so they are rendered client side. This handles issues surrounding lazy loading. 
What does saving `this` to `self` do here?  Typically this is for when you need `self` as part of a closure right?  Most of this function continues to use `this` and the one use of `self` on line 76 seems the same as these other usages.