rewrite instagram gallery as revealing module pattern