adds attempt at making js lightbox more dynamic